Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I solve "Greetings, time traveller. We are in the golden age of prefix-less CSS, where Autoprefixer is no longer needed for your stylesheet."?

Tags:

In my Next.JS app I import my stylesheet in _app.js like this:

import '../public/css/Index.css'; 

Index.css contains this:

.index-container {     margin: 20px auto 0; } 

How do I solve the error message:

./src/public/css/Index.css (./node_modules/css-loader/dist/cjs.js??ref--5-oneOf-5-1!./node_modules/next/dist/compiled/postcss-loader??__nextjs_postcss!./src/public/css/Index.css) Warning

Greetings, time traveller. We are in the golden age of prefix-less CSS, where Autoprefixer is no longer needed for your stylesheet.

like image 395
strangeQuirks Avatar asked Jul 13 '20 19:07

strangeQuirks


1 Answers

Your issue can be solved package.json by applying code below:

 "browserslist": {     "production": [       ">0.3%",       "not ie 11",       "not dead",        "not op_mini all"     ],     "development": [       "last 1 chrome version",       "last 1 firefox version",       "last 1 safari version",       ">0.3%",       "not ie 11",       "not dead",        "not op_mini all"     ]   } 

After you have made these changes restart your server. you will no longer get this warning.

like image 128
Ian90 Avatar answered Nov 16 '22 07:11

Ian90