Remove default "noopener noreferrer nofollow" options

ooh, interesting problem :slight_smile:

I’ve seen that in the meantime 3.6.0 has switched to "noopener noreferrer".

But for further customization here’s a workaround (maybe a bit less hacky than patching the panel dist file):

  1. Create a plugin

    index.js

    panel.plugin('rasteiner/oh-hai-mark', { 
      components: {
        'k-writer': {
          extends: 'k-writer',
          mounted() {
            this.editor.marks.link.toDOM = node => ["a", {
              ...node.attrs,
              // rel: "noopener noreferrer", // NOPE!
            }, 0]
          }
        }
      }
    });
    

    index.php:

    <?php 
    use Kirby\Cms\App as Kirby;
    
    Kirby::plugin('rasteiner/oh-hai-mark', []);
    
  2. Use it.

2 Likes