@unpackjs/core 4.4.0 → 4.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/compiled/css-loader/index.js +20 -20
- package/compiled/css-loader/package.json +1 -1
- package/compiled/launch-editor/index.js +19 -12
- package/compiled/launch-editor/package.json +1 -1
- package/compiled/less-loader/index.js +8 -8
- package/compiled/postcss-loader/index.js +114 -110
- package/compiled/postcss-loader/package.json +1 -1
- package/compiled/sass-loader/index.js +8 -8
- package/dist/index.js +114 -184
- package/dist-types/bundler-config/cache.d.ts.map +1 -1
- package/dist-types/bundler-config/css.d.ts.map +1 -1
- package/dist-types/bundler-config/helpers.d.ts +45 -0
- package/dist-types/bundler-config/helpers.d.ts.map +1 -1
- package/dist-types/bundler-config/index.d.ts.map +1 -1
- package/dist-types/bundler-config/nativeCss.d.ts.map +1 -1
- package/dist-types/bundler-config/plugins/progress/index.d.ts.map +1 -1
- package/dist-types/bundler-config/plugins/registerHooks.d.ts +0 -1
- package/dist-types/bundler-config/plugins/registerHooks.d.ts.map +1 -1
- package/dist-types/cli/injectFramework.d.ts +1 -1
- package/dist-types/cli/injectFramework.d.ts.map +1 -1
- package/dist-types/plugins/prebundle.d.ts.map +1 -1
- package/dist-types/plugins/unocss.d.ts.map +1 -1
- package/dist-types/progressBar.d.ts +2 -2
- package/dist-types/progressBar.d.ts.map +1 -1
- package/dist-types/types/config.d.ts +2 -1
- package/dist-types/types/config.d.ts.map +1 -1
- package/dist-types/types/plugin.d.ts +0 -1
- package/dist-types/types/plugin.d.ts.map +1 -1
- package/package.json +8 -7
package/dist/index.js
CHANGED
|
@@ -784,15 +784,12 @@ async function applyCacheConfig({ config, unpackConfig, envFilePaths }) {
|
|
|
784
784
|
buildDependencies.userBuildDependencies = cacheConfig.buildDependencies || [], buildDependencies.envFilePaths = envFilePaths;
|
|
785
785
|
let cacheDirectory = node_path.resolve(unpackConfig.root, cacheConfig.cacheDirectory || `${unpackConfig._context.cachePath}/cache`, utils_isDevServer() ? 'dev' : 'build');
|
|
786
786
|
return mergeConfig(config, {
|
|
787
|
-
cache:
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
type: 'filesystem',
|
|
794
|
-
directory: cacheDirectory
|
|
795
|
-
}
|
|
787
|
+
cache: {
|
|
788
|
+
type: 'persistent',
|
|
789
|
+
buildDependencies: Object.values(buildDependencies).flat(),
|
|
790
|
+
storage: {
|
|
791
|
+
type: 'filesystem',
|
|
792
|
+
directory: cacheDirectory
|
|
796
793
|
}
|
|
797
794
|
}
|
|
798
795
|
});
|
|
@@ -893,7 +890,39 @@ async function getEntry(root, customEntry) {
|
|
|
893
890
|
let getOutputFilename = ({ type, hash, async })=>{
|
|
894
891
|
let FILENAME = utils_isProd() && !1 !== hash ? PROD_DEFAULT_FILENAME : DEV_DEFAULT_FILENAME;
|
|
895
892
|
return async ? 'js' === type ? FILENAME.jsAsync : FILENAME.cssAsync : FILENAME[type];
|
|
896
|
-
}
|
|
893
|
+
}, getCssLoader = (unpackConfig)=>unpackConfig.css?.transformer === 'lightningcss' ? {
|
|
894
|
+
loader: 'builtin:lightningcss-loader',
|
|
895
|
+
options: {
|
|
896
|
+
targets: esVersionToBrowserslist(unpackConfig.build.target),
|
|
897
|
+
...unpackConfig.css?.lightningcssLoader
|
|
898
|
+
}
|
|
899
|
+
} : {
|
|
900
|
+
loader: getCompiledPkgPath('postcss-loader'),
|
|
901
|
+
options: {
|
|
902
|
+
sourceMap: unpackConfig.css?.sourceMap,
|
|
903
|
+
...unpackConfig.css?.postcssLoader
|
|
904
|
+
}
|
|
905
|
+
}, getSassLoader = (unpackConfig)=>({
|
|
906
|
+
loader: getCompiledPkgPath('sass-loader'),
|
|
907
|
+
options: {
|
|
908
|
+
api: 'modern-compiler',
|
|
909
|
+
implementation: getUserDepPath(unpackConfig.root, [
|
|
910
|
+
'sass-embedded',
|
|
911
|
+
'sass'
|
|
912
|
+
]),
|
|
913
|
+
sourceMap: unpackConfig.css?.sourceMap,
|
|
914
|
+
...unpackConfig.css?.sassLoader
|
|
915
|
+
}
|
|
916
|
+
}), getLessLoader = (unpackConfig)=>({
|
|
917
|
+
loader: getCompiledPkgPath('less-loader'),
|
|
918
|
+
options: mergeConfig({
|
|
919
|
+
lessOptions: {
|
|
920
|
+
javascriptEnabled: !0
|
|
921
|
+
},
|
|
922
|
+
implementation: getUserDepPath(unpackConfig.root, 'less'),
|
|
923
|
+
sourceMap: unpackConfig.css?.sourceMap
|
|
924
|
+
}, unpackConfig.css?.lessLoader || {})
|
|
925
|
+
});
|
|
897
926
|
var css_dirname = __rspack_dirname(__rspack_fileURLToPath(import.meta.url));
|
|
898
927
|
async function applyHtmlConfig({ config, unpackConfig }) {
|
|
899
928
|
let htmlConfig = unpackConfig.html || {}, { template, templateContent } = getHtmlTemplateOrContent(htmlConfig.template, unpackConfig.root), templateParameters = {
|
|
@@ -926,7 +955,7 @@ class JsMinifyPlugin {
|
|
|
926
955
|
apply(compiler) {
|
|
927
956
|
let meta = JSON.stringify({
|
|
928
957
|
name: jsMinify_PLUGIN_NAME,
|
|
929
|
-
version: "4.
|
|
958
|
+
version: "4.5.0",
|
|
930
959
|
options: this.minifyOptions
|
|
931
960
|
});
|
|
932
961
|
compiler.hooks.compilation.tap(jsMinify_PLUGIN_NAME, (compilation)=>{
|
|
@@ -988,11 +1017,9 @@ class Spinner {
|
|
|
988
1017
|
class ProgressBar {
|
|
989
1018
|
prefix = 'transforming';
|
|
990
1019
|
spinner = new Spinner();
|
|
991
|
-
update({
|
|
992
|
-
let { columns: terminalWidth } = process.stdout,
|
|
993
|
-
|
|
994
|
-
let loadingChar = this.spinner.getCurrentChar(), messageWidth = terminalWidth - this.prefix.length - (1 === current ? 10 : 9);
|
|
995
|
-
logUpdate(`${loadingChar} ${this.prefix} (${Math.floor(100 * current)}%) ${colors.dim(message.slice(0, messageWidth).padEnd(messageWidth, ' '))}`), 1 === current && clearLine();
|
|
1020
|
+
update({ percentage, message = '' }) {
|
|
1021
|
+
let { columns: terminalWidth } = process.stdout, loadingChar = this.spinner.getCurrentChar(), messageWidth = terminalWidth - this.prefix.length - (1 === percentage ? 10 : 9);
|
|
1022
|
+
logUpdate(`${loadingChar} ${this.prefix} (${Math.floor(100 * percentage)}%) ${colors.dim(message.slice(0, messageWidth).padEnd(messageWidth, ' '))}`), 1 === percentage && clearLine();
|
|
996
1023
|
}
|
|
997
1024
|
}
|
|
998
1025
|
function isLikelyFile(filePath) {
|
|
@@ -1054,10 +1081,10 @@ class ProgressLitePlugin {
|
|
|
1054
1081
|
class ProgressPlugin extends rspack.ProgressPlugin {
|
|
1055
1082
|
progressBar = new ProgressBar();
|
|
1056
1083
|
constructor(){
|
|
1057
|
-
super((percentage,
|
|
1084
|
+
super((percentage, message)=>{
|
|
1058
1085
|
utils_isProd() && this.progressBar.update({
|
|
1059
|
-
|
|
1060
|
-
message
|
|
1086
|
+
percentage,
|
|
1087
|
+
message
|
|
1061
1088
|
});
|
|
1062
1089
|
});
|
|
1063
1090
|
}
|
|
@@ -1070,7 +1097,6 @@ class ProgressPlugin extends rspack.ProgressPlugin {
|
|
|
1070
1097
|
let registerHooks_PLUGIN_NAME = 'RegisterHooksPlugin';
|
|
1071
1098
|
class RegisterHooksPlugin {
|
|
1072
1099
|
isFirstCompile = !0;
|
|
1073
|
-
lastVirtualModules = new Map();
|
|
1074
1100
|
lastLoadedModules = new Map();
|
|
1075
1101
|
resolveIdTimings = new Map();
|
|
1076
1102
|
loadTimings = new Map();
|
|
@@ -1116,15 +1142,9 @@ class RegisterHooksPlugin {
|
|
|
1116
1142
|
let loaded = await load(id);
|
|
1117
1143
|
null !== loaded && prev !== loaded && (this.lastLoadedModules.set(id, loaded), virtualModulesPlugin.writeModule(id, loaded));
|
|
1118
1144
|
}
|
|
1119
|
-
}, updateVirtualModules = ()=>{
|
|
1120
|
-
applyPluginsByHookSync('virtualModules', (impl)=>{
|
|
1121
|
-
Object.entries(impl()).forEach(([path, content])=>{
|
|
1122
|
-
this.lastVirtualModules.get(path) !== content && (this.lastVirtualModules.set(path, content), virtualModulesPlugin.writeModule(path, content));
|
|
1123
|
-
});
|
|
1124
|
-
});
|
|
1125
1145
|
};
|
|
1126
1146
|
compiler.hooks.thisCompilation.tap(registerHooks_PLUGIN_NAME, (compilation)=>{
|
|
1127
|
-
|
|
1147
|
+
applyPluginsByHookSync('processAssets', (impl, plugin)=>{
|
|
1128
1148
|
let { stage, handler } = impl;
|
|
1129
1149
|
compilation.hooks.processAssets.tapPromise({
|
|
1130
1150
|
name: registerHooks_PLUGIN_NAME,
|
|
@@ -1168,7 +1188,7 @@ class RegisterHooksPlugin {
|
|
|
1168
1188
|
}), this.isFirstCompile = !1;
|
|
1169
1189
|
}), compiler.hooks.afterDone.tap(registerHooks_PLUGIN_NAME, ()=>{
|
|
1170
1190
|
this.isCompiling = !1, isDev() && (clearTimeout(this.idleTimer), this.idleTimer = setTimeout(()=>{
|
|
1171
|
-
this.isCompiling ||
|
|
1191
|
+
this.isCompiling || updateLoadedModules();
|
|
1172
1192
|
}, 50));
|
|
1173
1193
|
});
|
|
1174
1194
|
}
|
|
@@ -1313,9 +1333,14 @@ async function getBundlerConfig(originalUnpackConfig) {
|
|
|
1313
1333
|
{
|
|
1314
1334
|
test: /\.wasm$/,
|
|
1315
1335
|
dependency: 'url',
|
|
1316
|
-
type: '
|
|
1336
|
+
type: 'webassembly/async'
|
|
1317
1337
|
}
|
|
1318
|
-
]
|
|
1338
|
+
],
|
|
1339
|
+
parser: {
|
|
1340
|
+
javascript: {
|
|
1341
|
+
exportsPresence: 'warn'
|
|
1342
|
+
}
|
|
1343
|
+
}
|
|
1319
1344
|
},
|
|
1320
1345
|
plugins: [
|
|
1321
1346
|
new rspack.DefinePlugin({
|
|
@@ -1365,8 +1390,6 @@ async function getBundlerConfig(originalUnpackConfig) {
|
|
|
1365
1390
|
entries: !!unpackConfig.mpa
|
|
1366
1391
|
},
|
|
1367
1392
|
experiments: {
|
|
1368
|
-
css: !1,
|
|
1369
|
-
asyncWebAssembly: !0,
|
|
1370
1393
|
nativeWatcher: !0
|
|
1371
1394
|
},
|
|
1372
1395
|
optimization: {
|
|
@@ -1447,11 +1470,6 @@ async function getBundlerConfig(originalUnpackConfig) {
|
|
|
1447
1470
|
hash: unpackConfig.build?.filenameHash,
|
|
1448
1471
|
async: !0
|
|
1449
1472
|
}), set(config, [
|
|
1450
|
-
'experiments',
|
|
1451
|
-
'css'
|
|
1452
|
-
], !0);
|
|
1453
|
-
let sourceMap = unpackConfig.css?.sourceMap;
|
|
1454
|
-
set(config, [
|
|
1455
1473
|
'module',
|
|
1456
1474
|
'parser',
|
|
1457
1475
|
'css/module'
|
|
@@ -1465,103 +1483,47 @@ async function getBundlerConfig(originalUnpackConfig) {
|
|
|
1465
1483
|
localIdentName: CSS_MODULES_LOCAL_IDENT_NAME,
|
|
1466
1484
|
exportsConvention: CSS_MODULES_EXPORTS_CONVENTION
|
|
1467
1485
|
});
|
|
1468
|
-
let
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
}
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
'sass'
|
|
1505
|
-
]),
|
|
1506
|
-
sourceMap,
|
|
1507
|
-
...unpackConfig.css?.sassLoader
|
|
1508
|
-
}
|
|
1509
|
-
});
|
|
1510
|
-
return config.module.rules.push({
|
|
1511
|
-
test: /\.css$/i,
|
|
1512
|
-
oneOf: [
|
|
1513
|
-
withCssModules({
|
|
1514
|
-
use: [
|
|
1515
|
-
getCssLoader()
|
|
1516
|
-
]
|
|
1517
|
-
}),
|
|
1518
|
-
{
|
|
1519
|
-
use: [
|
|
1520
|
-
getCssLoader()
|
|
1521
|
-
],
|
|
1522
|
-
type: 'css'
|
|
1523
|
-
}
|
|
1524
|
-
].filter(Boolean)
|
|
1525
|
-
}), config.module.rules.push({
|
|
1526
|
-
test: /\.less$/i,
|
|
1527
|
-
oneOf: [
|
|
1528
|
-
withCssModules({
|
|
1529
|
-
use: [
|
|
1530
|
-
getCssLoader(),
|
|
1531
|
-
getLessLoader()
|
|
1532
|
-
]
|
|
1533
|
-
}),
|
|
1534
|
-
{
|
|
1535
|
-
use: [
|
|
1536
|
-
getCssLoader(),
|
|
1537
|
-
getLessLoader()
|
|
1538
|
-
],
|
|
1539
|
-
type: 'css'
|
|
1540
|
-
}
|
|
1541
|
-
].filter(Boolean)
|
|
1542
|
-
}), config.module.rules.push({
|
|
1543
|
-
test: /\.s[ac]ss$/i,
|
|
1544
|
-
oneOf: [
|
|
1545
|
-
withCssModules({
|
|
1546
|
-
use: [
|
|
1547
|
-
getCssLoader(),
|
|
1548
|
-
getSassLoader()
|
|
1549
|
-
]
|
|
1550
|
-
}),
|
|
1551
|
-
{
|
|
1552
|
-
use: [
|
|
1553
|
-
getCssLoader(),
|
|
1554
|
-
getSassLoader()
|
|
1555
|
-
],
|
|
1556
|
-
type: 'css'
|
|
1557
|
-
}
|
|
1558
|
-
].filter(Boolean)
|
|
1559
|
-
}), config;
|
|
1486
|
+
let createStyleRule = (test, items)=>{
|
|
1487
|
+
let use = items.filter(Boolean);
|
|
1488
|
+
return {
|
|
1489
|
+
test,
|
|
1490
|
+
oneOf: [
|
|
1491
|
+
(({ use })=>({
|
|
1492
|
+
resourceQuery: /[?&]module(?:[=&]|$)/,
|
|
1493
|
+
use: [
|
|
1494
|
+
isDev() && {
|
|
1495
|
+
loader: node_path.resolve(nativeCss_dirname, './typedCssModulesLoader.js')
|
|
1496
|
+
},
|
|
1497
|
+
...use
|
|
1498
|
+
].filter(Boolean),
|
|
1499
|
+
type: 'css/module'
|
|
1500
|
+
}))({
|
|
1501
|
+
use
|
|
1502
|
+
}),
|
|
1503
|
+
{
|
|
1504
|
+
use,
|
|
1505
|
+
type: 'css'
|
|
1506
|
+
}
|
|
1507
|
+
]
|
|
1508
|
+
};
|
|
1509
|
+
};
|
|
1510
|
+
return config.module.rules.push(createStyleRule(/\.css$/i, [
|
|
1511
|
+
getCssLoader(unpackConfig),
|
|
1512
|
+
unpackConfig.css?.tailwindcss && {
|
|
1513
|
+
loader: require.resolve('@tailwindcss/webpack')
|
|
1514
|
+
}
|
|
1515
|
+
])), config.module.rules.push(createStyleRule(/\.less$/i, [
|
|
1516
|
+
getCssLoader(unpackConfig),
|
|
1517
|
+
getLessLoader(unpackConfig)
|
|
1518
|
+
])), config.module.rules.push(createStyleRule(/\.s[ac]ss$/i, [
|
|
1519
|
+
getCssLoader(unpackConfig),
|
|
1520
|
+
getSassLoader(unpackConfig)
|
|
1521
|
+
])), config;
|
|
1560
1522
|
}({
|
|
1561
1523
|
config,
|
|
1562
1524
|
unpackConfig
|
|
1563
1525
|
}) : function({ config, unpackConfig }) {
|
|
1564
|
-
let
|
|
1526
|
+
let getCommonRules = ({ importLoaders })=>[
|
|
1565
1527
|
utils_isDevServer() ? {
|
|
1566
1528
|
loader: getCompiledPkgPath('style-loader')
|
|
1567
1529
|
} : {
|
|
@@ -1583,11 +1545,11 @@ async function getBundlerConfig(originalUnpackConfig) {
|
|
|
1583
1545
|
exportLocalsConvention: CSS_MODULES_EXPORTS_CONVENTION,
|
|
1584
1546
|
namedExport: !1
|
|
1585
1547
|
},
|
|
1586
|
-
sourceMap
|
|
1548
|
+
sourceMap: unpackConfig.css?.sourceMap
|
|
1587
1549
|
}
|
|
1588
1550
|
}
|
|
1589
1551
|
].filter(Boolean);
|
|
1590
|
-
utils_isDevServer() || config.plugins.push(new rspack.CssExtractRspackPlugin({
|
|
1552
|
+
return utils_isDevServer() || config.plugins.push(new rspack.CssExtractRspackPlugin({
|
|
1591
1553
|
filename: getOutputFilename({
|
|
1592
1554
|
type: 'css',
|
|
1593
1555
|
hash: unpackConfig.build?.filenameHash
|
|
@@ -1598,65 +1560,34 @@ async function getBundlerConfig(originalUnpackConfig) {
|
|
|
1598
1560
|
async: !0
|
|
1599
1561
|
}),
|
|
1600
1562
|
ignoreOrder: !0
|
|
1601
|
-
}))
|
|
1602
|
-
let getCssLoader = ()=>unpackConfig.css?.transformer === 'lightningcss' ? {
|
|
1603
|
-
loader: 'builtin:lightningcss-loader',
|
|
1604
|
-
options: {
|
|
1605
|
-
targets: esVersionToBrowserslist(unpackConfig.build.target),
|
|
1606
|
-
...unpackConfig.css?.lightningcssLoader
|
|
1607
|
-
}
|
|
1608
|
-
} : {
|
|
1609
|
-
loader: getCompiledPkgPath('postcss-loader'),
|
|
1610
|
-
options: {
|
|
1611
|
-
sourceMap,
|
|
1612
|
-
...unpackConfig.css?.postcssLoader
|
|
1613
|
-
}
|
|
1614
|
-
};
|
|
1615
|
-
return config.module.rules.push({
|
|
1563
|
+
})), config.module.rules.push({
|
|
1616
1564
|
test: /\.less$/i,
|
|
1617
1565
|
use: [
|
|
1618
1566
|
...getCommonRules({
|
|
1619
1567
|
importLoaders: 2
|
|
1620
1568
|
}),
|
|
1621
|
-
getCssLoader(),
|
|
1622
|
-
|
|
1623
|
-
loader: getCompiledPkgPath('less-loader'),
|
|
1624
|
-
options: mergeConfig({
|
|
1625
|
-
lessOptions: {
|
|
1626
|
-
javascriptEnabled: !0
|
|
1627
|
-
},
|
|
1628
|
-
implementation: getUserDepPath(unpackConfig.root, 'less'),
|
|
1629
|
-
sourceMap
|
|
1630
|
-
}, unpackConfig.css?.lessLoader || {})
|
|
1631
|
-
}
|
|
1569
|
+
getCssLoader(unpackConfig),
|
|
1570
|
+
getLessLoader(unpackConfig)
|
|
1632
1571
|
]
|
|
1633
1572
|
}), config.module.rules.push({
|
|
1634
1573
|
test: /\.css$/i,
|
|
1635
1574
|
use: [
|
|
1636
1575
|
...getCommonRules({
|
|
1637
|
-
importLoaders: 1
|
|
1576
|
+
importLoaders: unpackConfig.css?.tailwindcss ? 2 : 1
|
|
1638
1577
|
}),
|
|
1639
|
-
getCssLoader()
|
|
1640
|
-
|
|
1578
|
+
getCssLoader(unpackConfig),
|
|
1579
|
+
unpackConfig.css?.tailwindcss && {
|
|
1580
|
+
loader: require.resolve('@tailwindcss/webpack')
|
|
1581
|
+
}
|
|
1582
|
+
].filter(Boolean)
|
|
1641
1583
|
}), config.module.rules.push({
|
|
1642
1584
|
test: /\.s[ac]ss$/i,
|
|
1643
1585
|
use: [
|
|
1644
1586
|
...getCommonRules({
|
|
1645
1587
|
importLoaders: 2
|
|
1646
1588
|
}),
|
|
1647
|
-
getCssLoader(),
|
|
1648
|
-
|
|
1649
|
-
loader: getCompiledPkgPath('sass-loader'),
|
|
1650
|
-
options: {
|
|
1651
|
-
api: 'modern-compiler',
|
|
1652
|
-
implementation: getUserDepPath(unpackConfig.root, [
|
|
1653
|
-
'sass-embedded',
|
|
1654
|
-
'sass'
|
|
1655
|
-
]),
|
|
1656
|
-
sourceMap,
|
|
1657
|
-
...unpackConfig.css?.sassLoader
|
|
1658
|
-
}
|
|
1659
|
-
}
|
|
1589
|
+
getCssLoader(unpackConfig),
|
|
1590
|
+
getSassLoader(unpackConfig)
|
|
1660
1591
|
]
|
|
1661
1592
|
}), config;
|
|
1662
1593
|
}({
|
|
@@ -1839,7 +1770,7 @@ async function unpackDev(unpackConfig) {
|
|
|
1839
1770
|
...middlewares
|
|
1840
1771
|
]);
|
|
1841
1772
|
let server = new RspackDevServer(devServerOptions, compiler);
|
|
1842
|
-
await server.start(), logger_logger.greet(` ${colors.brand(`${colors.bold(unpackConfig._context.callerName.toUpperCase())} v4.
|
|
1773
|
+
await server.start(), logger_logger.greet(` ${colors.brand(`${colors.bold(unpackConfig._context.callerName.toUpperCase())} v4.5.0`)} ${colors.dim('ready in')} ${colors.bold(Math.ceil(performance.now() - getUnpackStartTime()))} ${colors.dim('ms')}\n`), printServerUrls({
|
|
1843
1774
|
port,
|
|
1844
1775
|
host: unpackConfig.server.host,
|
|
1845
1776
|
base: unpackConfig.base
|
|
@@ -1853,7 +1784,7 @@ async function unpackDev(unpackConfig) {
|
|
|
1853
1784
|
function createUnpack({ cwd = process.cwd(), config: userConfig, callerName = 'unpack' }) {
|
|
1854
1785
|
let _context = {
|
|
1855
1786
|
callerName,
|
|
1856
|
-
version: "4.
|
|
1787
|
+
version: "4.5.0",
|
|
1857
1788
|
cachePath: 'node_modules/.unpack'
|
|
1858
1789
|
}, resolveConfig = (mode)=>{
|
|
1859
1790
|
let rootPath, outputPath, basePath, cachedTraceMap, fs, isValidMethodName, parseFrame, formatOriginalLocation, formatFullStack, resolveErrorLocationAndStack, root, alias, shouldTransformDeepImport, preJsAssets, jsAssets, cssAssets, bundledDepsCachePath, deepImportPkgPattern, deepImportRegex, plugin, root1, uno, generated, configOrPathFromUnpackConfig, defaultsFromUnpackConfig, VIRTUAL_UNO_CSS_ID, rootDir, isMpa, unoConfig, configFilePath, unpackConfigPath, tokens, requestedLayers, tasks, unocssCacheDir, tokensCachePath, layersCachePath, timeCachePath, configHashCachePath, generatedCachePath, bundlerCacheDir, cachedTokensSize, cachedLayersSize, isCompiling, resolveUnocssConfig, flushTasks, getVirtualModuleContent, hash, restoreSkipCode, applyUnoTransformers, optionsFromUnpackConfig, rootPath1, registerCode, namesCode, defaultConfig = {
|
|
@@ -1874,7 +1805,7 @@ function createUnpack({ cwd = process.cwd(), config: userConfig, callerName = 'u
|
|
|
1874
1805
|
mountId: 'root'
|
|
1875
1806
|
},
|
|
1876
1807
|
css: {
|
|
1877
|
-
transformer: '
|
|
1808
|
+
transformer: 'lightningcss',
|
|
1878
1809
|
sourceMap: !1
|
|
1879
1810
|
},
|
|
1880
1811
|
performance: {
|
|
@@ -2434,9 +2365,6 @@ function createUnpack({ cwd = process.cwd(), config: userConfig, callerName = 'u
|
|
|
2434
2365
|
optimization: {
|
|
2435
2366
|
splitChunks: !1
|
|
2436
2367
|
},
|
|
2437
|
-
experiments: {
|
|
2438
|
-
css: !0
|
|
2439
|
-
},
|
|
2440
2368
|
externals: depExternals
|
|
2441
2369
|
});
|
|
2442
2370
|
compiler.run((_, stats)=>{
|
|
@@ -2793,7 +2721,7 @@ function createUnpack({ cwd = process.cwd(), config: userConfig, callerName = 'u
|
|
|
2793
2721
|
let mode = watch ? 'development' : 'production';
|
|
2794
2722
|
setNodeEnv(mode);
|
|
2795
2723
|
let config = resolveConfig(mode);
|
|
2796
|
-
console.log(colors.brand(`${callerName} v4.
|
|
2724
|
+
console.log(colors.brand(`${callerName} v4.5.0`), colors.cyan(`building for ${mode}...`)), await unpackBuild(config);
|
|
2797
2725
|
},
|
|
2798
2726
|
dev: async ()=>{
|
|
2799
2727
|
setUnpackStartTime(performance.now());
|
|
@@ -2824,8 +2752,10 @@ async function createChokidar(pathOrGlobs, root = process.cwd(), options) {
|
|
|
2824
2752
|
var injectFramework_dirname = __rspack_dirname(__rspack_fileURLToPath(import.meta.url));
|
|
2825
2753
|
async function injectFrameworkPluginForDebug(userConfig) {
|
|
2826
2754
|
var plugin;
|
|
2827
|
-
let
|
|
2828
|
-
|
|
2755
|
+
let framework = process.env.FRAMEWORK?.trim();
|
|
2756
|
+
if (!framework) return;
|
|
2757
|
+
let pluginPath = node_path.resolve(injectFramework_dirname, `../../plugin-${framework}/dist/index.js`);
|
|
2758
|
+
node_fs.existsSync(pluginPath) && (plugin = (0, (await import(pluginPath))[`plugin${framework.charAt(0).toUpperCase() + framework.slice(1)}`])(), userConfig.plugins ? userConfig.plugins.unshift(plugin) : userConfig.plugins = [
|
|
2829
2759
|
plugin
|
|
2830
2760
|
]);
|
|
2831
2761
|
}
|
|
@@ -2942,7 +2872,7 @@ function runCLI() {
|
|
|
2942
2872
|
logger_logger.clear(), logger_logger.info(`${node_path.basename(file)} changed, restarting server...`), await watcher.close(), await cleanUpBeforeRestart(), startServer(options);
|
|
2943
2873
|
});
|
|
2944
2874
|
});
|
|
2945
|
-
devCommand.option('-o, --open [url]', 'Open browser on startup').option('--port <port>', 'Specify port').option('--host', 'Expose hostname').action(startServer), cli.help(), cli.version("4.
|
|
2875
|
+
devCommand.option('-o, --open [url]', 'Open browser on startup').option('--port <port>', 'Specify port').option('--host', 'Expose hostname').action(startServer), cli.help(), cli.version("4.5.0"), cli.parse();
|
|
2946
2876
|
}
|
|
2947
2877
|
var src_CSS_MODULES_NAMED_EXPORT = !1;
|
|
2948
2878
|
export { ALL_INTERFACES_IPV4, CSS_MODULES_EXPORTS_CONVENTION, CSS_MODULES_LOCAL_IDENT_NAME, DEV_DEFAULT_FILENAME, JSX_REGEX, JS_REGEX, LOCALHOST, NODE_MODULES_REGEX, PROD_DEFAULT_FILENAME, SCRIPT_REGEX, TEMPLATE_CONTENT, addRestartCleaner, applyHtmlTagDescriptors, cleanUpBeforeRestart, clearLine, colors, convertBasicAnsiColors, createChokidar, createUnpack, debounce, defineConfig, emptyDir, ensureDir, esVersionToBrowserslist, external_tinyglobby_glob as glob, findExists, getAddressUrls, getCompiledPkgPath, getCurrentUnpackConfig, getFilesContentHash, getHtmlTemplateOrContent, getIpv4Interfaces, getNodeEnv, getOrSetDefault, getPathInJs, getPort, getTime, getUnpackStartTime, getUserDepPath, getUserDepVersion, globSync, isBoolean, isDebug, isDev, isEmptyDir, isFileExists, isFileSync, isFunction, isNodeVersionAtLeast, isObject, isPlainObject, isRegExp, isString, isUndefined, isWin, launchEditor, loadConfig, loadConfigFromFile, logUpdate, logger_LogColor as LogColor, logger_logger as logger, mergeConfig, normalizePublicPath, openBrowser, pLimit, pathExists, pathToExportIdentifier, prettyTime, printServerUrls, removeDir, renderHtmlTagDescriptor, resolveConfigPath, rspack, runCLI, set, setCurrentUnpackConfig, setDevServer, setNodeEnv, setUnpackStartTime, src_CSS_MODULES_NAMED_EXPORT as CSS_MODULES_NAMED_EXPORT, trackPerformance, utils_isDevServer as isDevServer, utils_isProd as isProd };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cache.d.ts","sourceRoot":"","sources":["../../src/bundler-config/cache.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAoC5D,wBAAsB,gBAAgB,CAAC,EACrC,MAAM,EACN,YAAY,EACZ,YAAY,GACb,EAAE;IACD,MAAM,EAAE,aAAa,CAAA;IACrB,YAAY,EAAE,YAAY,CAAA;IAC1B,YAAY,EAAE,MAAM,EAAE,CAAA;CACvB,GAAG,OAAO,CAAC,aAAa,CAAC,
|
|
1
|
+
{"version":3,"file":"cache.d.ts","sourceRoot":"","sources":["../../src/bundler-config/cache.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAoC5D,wBAAsB,gBAAgB,CAAC,EACrC,MAAM,EACN,YAAY,EACZ,YAAY,GACb,EAAE;IACD,MAAM,EAAE,aAAa,CAAA;IACrB,YAAY,EAAE,YAAY,CAAA;IAC1B,YAAY,EAAE,MAAM,EAAE,CAAA;CACvB,GAAG,OAAO,CAAC,aAAa,CAAC,CAuBzB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../../src/bundler-config/css.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,aAAa,EAAU,YAAY,EAAE,MAAM,WAAW,CAAA;
|
|
1
|
+
{"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../../src/bundler-config/css.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,aAAa,EAAU,YAAY,EAAE,MAAM,WAAW,CAAA;AAUpE,wBAAgB,cAAc,CAAC,EAC7B,MAAM,EACN,YAAY,GACb,EAAE;IACD,MAAM,EAAE,aAAa,CAAA;IACrB,YAAY,EAAE,YAAY,CAAA;CAC3B,GAAG,aAAa,CA4EhB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Rspack, UnpackConfig } from '../types';
|
|
1
2
|
export declare function getEntry(root: string, customEntry: string): Promise<string>;
|
|
2
3
|
type OutputFilename = {
|
|
3
4
|
type: 'js' | 'css';
|
|
@@ -5,5 +6,49 @@ type OutputFilename = {
|
|
|
5
6
|
async?: boolean;
|
|
6
7
|
};
|
|
7
8
|
export declare const getOutputFilename: ({ type, hash, async }: OutputFilename) => string;
|
|
9
|
+
export declare const resolveRuleUse: (items: Array<Rspack.RuleSetUseItem | false | undefined>) => Rspack.RuleSetUseItem[];
|
|
10
|
+
export declare const getCssLoader: (unpackConfig: UnpackConfig) => {
|
|
11
|
+
loader: string;
|
|
12
|
+
options: {
|
|
13
|
+
minify?: boolean;
|
|
14
|
+
errorRecovery?: boolean;
|
|
15
|
+
targets: import("node_modules/@rspack/core/dist/builtin-loader/lightningcss").Targets | string[] | string;
|
|
16
|
+
include?: Rspack.LightningcssFeatureOptions;
|
|
17
|
+
exclude?: Rspack.LightningcssFeatureOptions;
|
|
18
|
+
drafts?: import("node_modules/@rspack/core/dist/builtin-loader/lightningcss").Drafts;
|
|
19
|
+
nonStandard?: import("node_modules/@rspack/core/dist/builtin-loader/lightningcss").NonStandard;
|
|
20
|
+
pseudoClasses?: import("node_modules/@rspack/core/dist/builtin-loader/lightningcss").PseudoClasses;
|
|
21
|
+
unusedSymbols?: string[];
|
|
22
|
+
};
|
|
23
|
+
} | {
|
|
24
|
+
loader: string;
|
|
25
|
+
options: {
|
|
26
|
+
execute?: boolean;
|
|
27
|
+
postcssOptions?: (import("postcss").ProcessOptions<import("postcss").Document | import("postcss").Root> & {
|
|
28
|
+
config?: boolean | string;
|
|
29
|
+
plugins?: import("postcss").AcceptedPlugin[];
|
|
30
|
+
}) | ((loaderContext: Rspack.LoaderContext) => import("postcss").ProcessOptions<import("postcss").Document | import("postcss").Root> & {
|
|
31
|
+
config?: boolean | string;
|
|
32
|
+
plugins?: import("postcss").AcceptedPlugin[];
|
|
33
|
+
});
|
|
34
|
+
sourceMap: boolean;
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
export declare const getSassLoader: (unpackConfig: UnpackConfig) => {
|
|
38
|
+
loader: string;
|
|
39
|
+
options: {
|
|
40
|
+
sassOptions?: any;
|
|
41
|
+
sourceMap: boolean;
|
|
42
|
+
additionalData?: string | ((content: string, loaderContext: Rspack.LoaderContext) => string);
|
|
43
|
+
webpackImporter?: boolean;
|
|
44
|
+
warnRuleAsWarning?: boolean;
|
|
45
|
+
api: string;
|
|
46
|
+
implementation: string | undefined;
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
export declare const getLessLoader: (unpackConfig: UnpackConfig) => {
|
|
50
|
+
loader: string;
|
|
51
|
+
options: any;
|
|
52
|
+
};
|
|
8
53
|
export {};
|
|
9
54
|
//# sourceMappingURL=helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../src/bundler-config/helpers.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../src/bundler-config/helpers.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAWrD,wBAAsB,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAejF;AAED,KAAK,cAAc,GAAG;IACpB,IAAI,EAAE,IAAI,GAAG,KAAK,CAAA;IAClB,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,KAAK,CAAC,EAAE,OAAO,CAAA;CAChB,CAAA;AAED,eAAO,MAAM,iBAAiB,GAAI,uBAAuB,cAAc,KAAG,MASzE,CAAA;AAED,eAAO,MAAM,cAAc,GAAI,OAAO,KAAK,CAAC,MAAM,CAAC,cAAc,GAAG,KAAK,GAAG,SAAS,CAAC,KAC3D,MAAM,CAAC,cAAc,EAAE,CAAA;AAElD,eAAO,MAAM,YAAY,GAAI,cAAc,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;CAgBtD,CAAA;AAED,eAAO,MAAM,aAAa,GAAI,cAAc,YAAY;;;;;;;;;;;CAUvD,CAAA;AAED,eAAO,MAAM,aAAa,GAAI,cAAc,YAAY;;;CAcvD,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/bundler-config/index.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAwB5D,wBAAsB,gBAAgB,CAAC,oBAAoB,EAAE,YAAY,GAAG,OAAO,CAAC,aAAa,CAAC,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/bundler-config/index.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAwB5D,wBAAsB,gBAAgB,CAAC,oBAAoB,EAAE,YAAY,GAAG,OAAO,CAAC,aAAa,CAAC,CAmNjG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nativeCss.d.ts","sourceRoot":"","sources":["../../src/bundler-config/nativeCss.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,aAAa,EAAU,YAAY,EAAE,MAAM,WAAW,CAAA;
|
|
1
|
+
{"version":3,"file":"nativeCss.d.ts","sourceRoot":"","sources":["../../src/bundler-config/nativeCss.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,aAAa,EAAU,YAAY,EAAE,MAAM,WAAW,CAAA;AAUpE,wBAAgB,oBAAoB,CAAC,EACnC,MAAM,EACN,YAAY,GACb,EAAE;IACD,MAAM,EAAE,aAAa,CAAA;IACrB,YAAY,EAAE,YAAY,CAAA;CAC3B,GAAG,aAAa,CAyDhB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/bundler-config/plugins/progress/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AACrC,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAC7C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAKvC,qBAAa,kBAAkB;IAC7B,KAAK,CAAC,QAAQ,EAAE,MAAM,CAAC,QAAQ,GAAG,IAAI;CAKvC;AAED,qBAAa,cAAe,SAAQ,MAAM,CAAC,cAAc;IACvD,WAAW,cAAoB;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/bundler-config/plugins/progress/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AACrC,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAC7C,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAKvC,qBAAa,kBAAkB;IAC7B,KAAK,CAAC,QAAQ,EAAE,MAAM,CAAC,QAAQ,GAAG,IAAI;CAKvC;AAED,qBAAa,cAAe,SAAQ,MAAM,CAAC,cAAc;IACvD,WAAW,cAAoB;;IAM/B,KAAK,CAAC,QAAQ,EAAE,MAAM,CAAC,QAAQ,GAAG,IAAI;CAMvC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"registerHooks.d.ts","sourceRoot":"","sources":["../../../src/bundler-config/plugins/registerHooks.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAIvC,qBAAa,mBAAmB;IAC9B,OAAO,CAAC,cAAc,CAAO;IAC7B,OAAO,CAAC,
|
|
1
|
+
{"version":3,"file":"registerHooks.d.ts","sourceRoot":"","sources":["../../../src/bundler-config/plugins/registerHooks.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAIvC,qBAAa,mBAAmB;IAC9B,OAAO,CAAC,cAAc,CAAO;IAC7B,OAAO,CAAC,iBAAiB,CAA4B;IACrD,OAAO,CAAC,gBAAgB,CAA4B;IACpD,OAAO,CAAC,WAAW,CAA4B;IAC/C,OAAO,CAAC,WAAW,CAAQ;IAC3B,OAAO,CAAC,SAAS,CAAwC;IACzD,KAAK,CAAC,QAAQ,EAAE,MAAM,CAAC,QAAQ,GAAG,IAAI;CA2IvC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { UnpackConfig } from '../types';
|
|
2
2
|
/**
|
|
3
|
-
* This should only
|
|
3
|
+
* This should only use in local development.
|
|
4
4
|
*/
|
|
5
5
|
export declare function injectFrameworkPluginForDebug(userConfig: UnpackConfig): Promise<void>;
|
|
6
6
|
//# sourceMappingURL=injectFramework.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"injectFramework.d.ts","sourceRoot":"","sources":["../../src/cli/injectFramework.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"injectFramework.d.ts","sourceRoot":"","sources":["../../src/cli/injectFramework.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAgB,MAAM,WAAW,CAAA;AAU3D;;GAEG;AACH,wBAAsB,6BAA6B,CAAC,UAAU,EAAE,YAAY,iBAS3E"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prebundle.d.ts","sourceRoot":"","sources":["../../src/plugins/prebundle.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAA0C,YAAY,EAAE,MAAM,WAAW,CAAA;AAkGrF,eAAO,MAAM,eAAe,QAAO,
|
|
1
|
+
{"version":3,"file":"prebundle.d.ts","sourceRoot":"","sources":["../../src/plugins/prebundle.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAA0C,YAAY,EAAE,MAAM,WAAW,CAAA;AAkGrF,eAAO,MAAM,eAAe,QAAO,YAkZlC,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"unocss.d.ts","sourceRoot":"","sources":["../../src/plugins/unocss.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAIV,UAAU,EACV,kBAAkB,EACnB,MAAM,cAAc,CAAA;AAOrB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAU7C,MAAM,MAAM,mBAAmB,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IAAI,UAAU,CAAC,KAAK,CAAC,CAAA;AAClF,MAAM,MAAM,oBAAoB,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IAAI,kBAAkB,CAAC,KAAK,CAAC,CAAA;AAoE3F,eAAO,MAAM,YAAY,GAAI,KAAK,SAAS,MAAM,EAC/C,eAAe,mBAAmB,CAAC,KAAK,CAAC,GAAG,MAAM,EAClD,WAAW,oBAAoB,CAAC,KAAK,CAAC,KACrC,
|
|
1
|
+
{"version":3,"file":"unocss.d.ts","sourceRoot":"","sources":["../../src/plugins/unocss.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAIV,UAAU,EACV,kBAAkB,EACnB,MAAM,cAAc,CAAA;AAOrB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAU7C,MAAM,MAAM,mBAAmB,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IAAI,UAAU,CAAC,KAAK,CAAC,CAAA;AAClF,MAAM,MAAM,oBAAoB,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,IAAI,kBAAkB,CAAC,KAAK,CAAC,CAAA;AAoE3F,eAAO,MAAM,YAAY,GAAI,KAAK,SAAS,MAAM,EAC/C,eAAe,mBAAmB,CAAC,KAAK,CAAC,GAAG,MAAM,EAClD,WAAW,oBAAoB,CAAC,KAAK,CAAC,KACrC,YAkWF,CAAA"}
|
|
@@ -2,8 +2,8 @@ import { Spinner } from './spinner';
|
|
|
2
2
|
export declare class ProgressBar {
|
|
3
3
|
prefix: string;
|
|
4
4
|
spinner: Spinner;
|
|
5
|
-
update({
|
|
6
|
-
|
|
5
|
+
update({ percentage, message }: {
|
|
6
|
+
percentage: number;
|
|
7
7
|
message?: string;
|
|
8
8
|
}): void;
|
|
9
9
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"progressBar.d.ts","sourceRoot":"","sources":["../src/progressBar.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAGnC,qBAAa,WAAW;IACtB,MAAM,SAAiB;IACvB,OAAO,UAAgB;IAEvB,MAAM,CAAC,EAAE,
|
|
1
|
+
{"version":3,"file":"progressBar.d.ts","sourceRoot":"","sources":["../src/progressBar.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAGnC,qBAAa,WAAW;IACtB,MAAM,SAAiB;IACvB,OAAO,UAAgB;IAEvB,MAAM,CAAC,EAAE,UAAU,EAAE,OAAY,EAAE,EAAE;QAAE,UAAU,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,MAAM,CAAA;KAAE;CAa9E"}
|
|
@@ -66,7 +66,7 @@ export type UnpackConfig = {
|
|
|
66
66
|
*/
|
|
67
67
|
native?: boolean;
|
|
68
68
|
/**
|
|
69
|
-
* @default "
|
|
69
|
+
* @default "lightningcss"
|
|
70
70
|
*/
|
|
71
71
|
transformer?: 'postcss' | 'lightningcss';
|
|
72
72
|
/**
|
|
@@ -81,6 +81,7 @@ export type UnpackConfig = {
|
|
|
81
81
|
* Unocss plugin options.
|
|
82
82
|
*/
|
|
83
83
|
unocss?: boolean | [configOrPath?: PluginUnocssOptions | string, defaults?: PluginUnocssDefaults];
|
|
84
|
+
tailwindcss?: boolean;
|
|
84
85
|
};
|
|
85
86
|
resolve?: {
|
|
86
87
|
/**
|