vercel / next.js

The React Framework
https://nextjs.org
MIT License
126.63k stars 26.93k forks source link

Autoprefixer Not Enabled by Default in create-next-app #70828

Open nadir opened 3 weeks ago

nadir commented 3 weeks ago

Link to the code that reproduces this issue

https://github.com/nadir/create-next-app-no-autoprefixer

To Reproduce

  1. Run npx create-next-app@latest my-next-app and select tailwind
  2. Navigate to the generated project directory.
  3. Open the postcss.config.js or postcss.config.mjs file.

Current vs. Expected behavior

Expected Behavior

The postcss.config.js or postcss.config.mjs file should include Autoprefixer in the plugins configuration.

Actual Behavior

The postcss.config.js or postcss.config.mjs file does not include Autoprefixer. Example file content:

/** @type {import('postcss-load-config').Config} */
const config = {
  plugins: {
    tailwindcss: {},
  },
};

export default config;

Provide environment information

Operating System:
  Platform: linux
  Arch: x64
  Version: #26~22.04.1-Ubuntu SMP Thu Jul 11 22:33:04 UTC 2024
  Available memory (MB): 7930
  Available CPU cores: 2
Binaries:
  Node: 20.17.0
  npm: 10.8.2
  Yarn: 1.22.22
  pnpm: 9.10.0
Relevant Packages:
  next: 14.2.3 // There is a newer version (14.2.14) available, upgrade recommended! 
  eslint-config-next: 14.2.3
  react: 18.3.1
  react-dom: 18.3.1
  typescript: 5.4.5

Which area(s) are affected? (Select all that apply)

create-next-app

Which stage(s) are affected? (Select all that apply)

next build (local)

Additional context

No response

nadir commented 1 week ago

Is this expected behaviour and should I close this issue ?