• Hi there,

    Hoping someone might be able to steer me in the right direction ??

    I’m trying to add browser prefixing for css using the postcss autoprefixer for my blocks built with @wordpress/create-block.

    e.g?{ display: -webkit-box; display: -ms-flexbox; display: flex; }

    From what I’ve seen online, it is possible to have a webpack.config.js file which overrides the default @wordpress/scripts one.

    I did create a github issue – https://github.com/WordPress/gutenberg/issues/45368 to see if it could be added as an optional flag or have it built in by default. But it doesn’t seemed to have gained much traction.

    Any insight would be much appreciated!

    Cheers!

Viewing 1 replies (of 1 total)
  • Hi there,

    From what I can see autoprefixer is enabled by default in the postcss plugins list used by the scripts package.

    I did a quick smoke test and got the following output:

    .block-editor-block-list__layout{-webkit-user-select:none;-moz-user-select:none;user-select:none}

    From the following CSS:

    .block-editor-block-list__layout{
        user-select:none;
    }

    Are you looking specifically to generate vendor prefixes for flexbox?

    Maybe flexbox requires an extra option, but I’m not sure when reading the docs. They say it’s enabled by default.

Viewing 1 replies (of 1 total)
  • The topic ‘Extending the @wordpress/create-block webpack.config’ is closed to new replies.