8000 perf: load default preset in startup by 43081j · Pull Request #1691 · cssnano/cssnano · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

perf: load default preset in startup #1691

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 18, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion packages/cssnano/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ const path = require('path');
/** @type {any} */
const postcss = require('postcss');
const { lilconfigSync } = require('lilconfig');
const defaultPreset = require('cssnano-preset-default');

const cssnano = 'cssnano';

Expand Down Expand Up @@ -48,7 +49,7 @@ function resolvePreset(preset) {

// Provide an alias for the default preset, as it is built-in.
if (fn === 'default') {
return require('cssnano-preset-default')(options).plugins;
return defaultPreset(options).plugins;
}

// For non-JS setups; we'll need to invoke the preset ourselves.
Expand Down
0