question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Include Autoprefixer

See original GitHub issue

I would like to know if we should include the setup needed to include autoprefixer into the webpack setup.

I found this a bit confusing to figure out how to implement into it given that autoprefixer recommends the use of postcss.

thus my loaders were

  if(env === productionEnvironment){
    loaders.push({
      test: /(\.css|\.scss)$/,
      include: path.join(__dirname, 'src'),
      loader: ExtractTextPlugin.extract("css?sourceMap!postcss!sass?sourceMap")
    });
  }else{
    loaders.push({
      test: /(\.css|\.scss)$/,
      include: path.join(__dirname, 'src'),
      loaders: ['style', 'css?sourceMap', 'postcss', 'sass?sourceMap']
    });
  }

and i also had to add to my config export

postcss: ()=> [autoprefixer]

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Reactions:1
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
coryhousecommented, Jul 25, 2016

Okay, enough people have asked, so I’m caving and adding it. 😃

PostCSS is now part of the story. For now, only autoprefixer is included, but open to a PR that adds linting.

Here’s the commit: https://github.com/coryhouse/react-slingshot/commit/582f0111a8bee0751c6afbca26ac215367ee7cb8

1reaction
darcnite3000commented, Feb 5, 2016

Pull request added #45

Read more comments on GitHub >

github_iconTop Results From Across the Web

postcss/autoprefixer: Parse CSS and add vendor prefixes to ...
Autoprefixer Cult Of Martians · PostCSS plugin to parse CSS and add vendor prefixes to CSS rules using values from Can I Use....
Read more >
autoprefixer - npm
Parse CSS and add vendor prefixes to CSS rules using values from the Can I Use website. Latest version: 10.4.13, last published: 2...
Read more >
How to Add CSS Vendor Prefixes Automatically - Medium
The autoprefixer is a PostCSS plugin to parse CSS and add vendor prefixes to CSS rules using values from Can I Use.
Read more >
Autoprefixer: A Postprocessor for Dealing with Vendor ...
Autoprefixer parses CSS files and adds vendor prefixes to CSS rules ... So after Autoprefixer, CSS will contain only actual vendor prefixes.
Read more >
Use Autoprefixer for browser compliant code - OpenClassrooms
“Autoprefixer” is a plugin that can save you from the monotony of -webkit- and -moz- . It does exactly what it sounds like:...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found