@bleedingdev/modern-js-utils 3.2.0-ultramodern.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/LICENSE +21 -0
- package/README.md +26 -0
- package/dist/cjs/cli/alias.js +82 -0
- package/dist/cjs/cli/applyOptionsChain.js +50 -0
- package/dist/cjs/cli/commands.js +69 -0
- package/dist/cjs/cli/common.js +59 -0
- package/dist/cjs/cli/config.js +39 -0
- package/dist/cjs/cli/constants.js +136 -0
- package/dist/cjs/cli/ensure.js +56 -0
- package/dist/cjs/cli/fs.js +46 -0
- package/dist/cjs/cli/get/config.js +48 -0
- package/dist/cjs/cli/get/data.js +106 -0
- package/dist/cjs/cli/get/index.js +112 -0
- package/dist/cjs/cli/index.js +212 -0
- package/dist/cjs/cli/is/config.js +86 -0
- package/dist/cjs/cli/is/env.js +52 -0
- package/dist/cjs/cli/is/index.js +79 -0
- package/dist/cjs/cli/is/project.js +147 -0
- package/dist/cjs/cli/is/type.js +84 -0
- package/dist/cjs/cli/logger.js +39 -0
- package/dist/cjs/cli/modulePath.js +87 -0
- package/dist/cjs/cli/monorepo.js +110 -0
- package/dist/cjs/cli/package.js +97 -0
- package/dist/cjs/cli/path.js +111 -0
- package/dist/cjs/cli/port.js +79 -0
- package/dist/cjs/cli/prettyInstructions.js +117 -0
- package/dist/cjs/cli/require.js +127 -0
- package/dist/cjs/cli/route.js +76 -0
- package/dist/cjs/cli/runtimeExports.js +86 -0
- package/dist/cjs/cli/tsconfig.js +51 -0
- package/dist/cjs/cli/version.js +67 -0
- package/dist/cjs/cli/watch.js +87 -0
- package/dist/cjs/compiled.js +209 -0
- package/dist/cjs/import.js +56 -0
- package/dist/cjs/index.js +72 -0
- package/dist/cjs/universal/constants.js +84 -0
- package/dist/cjs/universal/index.js +36 -0
- package/dist/cjs/universal/path.js +36 -0
- package/dist/cjs/universal/pluginDagSort.js +75 -0
- package/dist/compiled/address/index.js +171 -0
- package/dist/compiled/address/lib/address.d.ts +28 -0
- package/dist/compiled/address/package.json +1 -0
- package/dist/compiled/browserslist/index.d.ts +178 -0
- package/dist/compiled/browserslist/index.js +1329 -0
- package/dist/compiled/browserslist/license +20 -0
- package/dist/compiled/browserslist/package.json +1 -0
- package/dist/compiled/chalk/index.d.ts +415 -0
- package/dist/compiled/chalk/index.js +2368 -0
- package/dist/compiled/chalk/license +9 -0
- package/dist/compiled/chalk/package.json +1 -0
- package/dist/compiled/chokidar/anymatch/index.d.ts +19 -0
- package/dist/compiled/chokidar/fsevents.node +0 -0
- package/dist/compiled/chokidar/index.js +4162 -0
- package/dist/compiled/chokidar/index.js.LICENSE.txt +41 -0
- package/dist/compiled/chokidar/license +21 -0
- package/dist/compiled/chokidar/package.json +1 -0
- package/dist/compiled/chokidar/types/index.d.ts +188 -0
- package/dist/compiled/commander/index.js +1540 -0
- package/dist/compiled/commander/index.mjs +2 -0
- package/dist/compiled/commander/license +22 -0
- package/dist/compiled/commander/package.json +1 -0
- package/dist/compiled/commander/typings/index.d.ts +890 -0
- package/dist/compiled/debug/index.d.ts +54 -0
- package/dist/compiled/debug/index.js +621 -0
- package/dist/compiled/debug/license +20 -0
- package/dist/compiled/debug/ms/index.d.ts +25 -0
- package/dist/compiled/debug/package.json +1 -0
- package/dist/compiled/dotenv/index.js +101 -0
- package/dist/compiled/dotenv/license +23 -0
- package/dist/compiled/dotenv/package.json +1 -0
- package/dist/compiled/dotenv/types/index.d.ts +59 -0
- package/dist/compiled/dotenv-expand/index.d.ts +15 -0
- package/dist/compiled/dotenv-expand/index.js +54 -0
- package/dist/compiled/dotenv-expand/license +24 -0
- package/dist/compiled/dotenv-expand/package.json +1 -0
- package/dist/compiled/execa/index.d.ts +564 -0
- package/dist/compiled/execa/index.js +1738 -0
- package/dist/compiled/execa/license +9 -0
- package/dist/compiled/execa/package.json +1 -0
- package/dist/compiled/fast-glob/@nodelib/fs.scandir/out/adapters/fs.d.ts +20 -0
- package/dist/compiled/fast-glob/@nodelib/fs.scandir/out/index.d.ts +12 -0
- package/dist/compiled/fast-glob/@nodelib/fs.scandir/out/providers/async.d.ts +7 -0
- package/dist/compiled/fast-glob/@nodelib/fs.scandir/out/settings.d.ts +20 -0
- package/dist/compiled/fast-glob/@nodelib/fs.scandir/out/types/index.d.ts +20 -0
- package/dist/compiled/fast-glob/@nodelib/fs.stat/out/adapters/fs.d.ts +13 -0
- package/dist/compiled/fast-glob/@nodelib/fs.stat/out/index.d.ts +12 -0
- package/dist/compiled/fast-glob/@nodelib/fs.stat/out/providers/async.d.ts +4 -0
- package/dist/compiled/fast-glob/@nodelib/fs.stat/out/settings.d.ts +16 -0
- package/dist/compiled/fast-glob/@nodelib/fs.stat/out/types/index.d.ts +4 -0
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/index.d.ts +14 -0
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/providers/async.d.ts +12 -0
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/readers/async.d.ts +30 -0
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/readers/reader.d.ts +6 -0
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/settings.d.ts +30 -0
- package/dist/compiled/fast-glob/@nodelib/fs.walk/out/types/index.d.ts +8 -0
- package/dist/compiled/fast-glob/index.js +4665 -0
- package/dist/compiled/fast-glob/index.js.LICENSE.txt +38 -0
- package/dist/compiled/fast-glob/license +21 -0
- package/dist/compiled/fast-glob/out/index.d.ts +27 -0
- package/dist/compiled/fast-glob/out/managers/tasks.d.ts +22 -0
- package/dist/compiled/fast-glob/out/settings.d.ts +164 -0
- package/dist/compiled/fast-glob/out/types/index.d.ts +31 -0
- package/dist/compiled/fast-glob/package.json +1 -0
- package/dist/compiled/filesize/filesize.d.ts +131 -0
- package/dist/compiled/filesize/index.js +198 -0
- package/dist/compiled/filesize/index.js.LICENSE.txt +7 -0
- package/dist/compiled/filesize/license +28 -0
- package/dist/compiled/filesize/package.json +1 -0
- package/dist/compiled/fs-extra/index.d.ts +563 -0
- package/dist/compiled/fs-extra/index.js +2222 -0
- package/dist/compiled/fs-extra/license +15 -0
- package/dist/compiled/fs-extra/package.json +1 -0
- package/dist/compiled/glob/index.d.ts +91 -0
- package/dist/compiled/glob/index.js +2011 -0
- package/dist/compiled/glob/license +21 -0
- package/dist/compiled/glob/minimatch/index.d.ts +204 -0
- package/dist/compiled/glob/package.json +1 -0
- package/dist/compiled/globby/index.d.ts +186 -0
- package/dist/compiled/globby/index.js +690 -0
- package/dist/compiled/globby/license +9 -0
- package/dist/compiled/globby/package.json +1 -0
- package/dist/compiled/gzip-size/index.d.ts +96 -0
- package/dist/compiled/gzip-size/index.js +157 -0
- package/dist/compiled/gzip-size/license +9 -0
- package/dist/compiled/gzip-size/package.json +1 -0
- package/dist/compiled/import-lazy/index.d.ts +26 -0
- package/dist/compiled/import-lazy/index.js +45 -0
- package/dist/compiled/import-lazy/license +9 -0
- package/dist/compiled/import-lazy/package.json +1 -0
- package/dist/compiled/inquirer/index.d.ts +997 -0
- package/dist/compiled/inquirer/index.js +20167 -0
- package/dist/compiled/inquirer/index.js.LICENSE.txt +7 -0
- package/dist/compiled/inquirer/lib/objects/choice.d.ts +65 -0
- package/dist/compiled/inquirer/lib/objects/choices.d.ts +206 -0
- package/dist/compiled/inquirer/lib/objects/separator.d.ts +37 -0
- package/dist/compiled/inquirer/lib/ui/baseUI.d.ts +37 -0
- package/dist/compiled/inquirer/lib/ui/bottom-bar.d.ts +65 -0
- package/dist/compiled/inquirer/lib/ui/prompt.d.ts +104 -0
- package/dist/compiled/inquirer/license +22 -0
- package/dist/compiled/inquirer/package.json +1 -0
- package/dist/compiled/inquirer/through/index.d.ts +25 -0
- package/dist/compiled/js-yaml/index.d.ts +154 -0
- package/dist/compiled/js-yaml/index.js +2191 -0
- package/dist/compiled/js-yaml/index.mjs +2167 -0
- package/dist/compiled/js-yaml/index.mjs.LICENSE.txt +1 -0
- package/dist/compiled/js-yaml/license +21 -0
- package/dist/compiled/js-yaml/package.json +1 -0
- package/dist/compiled/json5/index.js +983 -0
- package/dist/compiled/json5/lib/index.d.ts +4 -0
- package/dist/compiled/json5/lib/parse.d.ts +15 -0
- package/dist/compiled/json5/lib/stringify.d.ts +89 -0
- package/dist/compiled/json5/package.json +1 -0
- package/dist/compiled/lodash/common/array.d.ts +2126 -0
- package/dist/compiled/lodash/common/collection.d.ts +1930 -0
- package/dist/compiled/lodash/common/common.d.ts +280 -0
- package/dist/compiled/lodash/common/date.d.ts +23 -0
- package/dist/compiled/lodash/common/function.d.ts +1446 -0
- package/dist/compiled/lodash/common/lang.d.ts +1693 -0
- package/dist/compiled/lodash/common/math.d.ts +405 -0
- package/dist/compiled/lodash/common/number.d.ts +131 -0
- package/dist/compiled/lodash/common/object.d.ts +2519 -0
- package/dist/compiled/lodash/common/seq.d.ts +210 -0
- package/dist/compiled/lodash/common/string.d.ts +788 -0
- package/dist/compiled/lodash/common/util.d.ts +1220 -0
- package/dist/compiled/lodash/index.d.ts +46 -0
- package/dist/compiled/lodash/index.js +1 -0
- package/dist/compiled/lodash/index.mjs +1 -0
- package/dist/compiled/lodash/license +47 -0
- package/dist/compiled/lodash/package.json +1 -0
- package/dist/compiled/mime-types/index.d.ts +14 -0
- package/dist/compiled/mime-types/index.js +116 -0
- package/dist/compiled/mime-types/index.js.LICENSE.txt +13 -0
- package/dist/compiled/mime-types/license +23 -0
- package/dist/compiled/mime-types/package.json +1 -0
- package/dist/compiled/minimist/index.d.ts +95 -0
- package/dist/compiled/minimist/index.js +202 -0
- package/dist/compiled/minimist/license +18 -0
- package/dist/compiled/minimist/package.json +1 -0
- package/dist/compiled/nanoid/index.d.ts +91 -0
- package/dist/compiled/nanoid/index.js +83 -0
- package/dist/compiled/nanoid/index.mjs +69 -0
- package/dist/compiled/nanoid/license +20 -0
- package/dist/compiled/nanoid/package.json +1 -0
- package/dist/compiled/ora/cli-spinners/index.d.ts +125 -0
- package/dist/compiled/ora/index.d.ts +277 -0
- package/dist/compiled/ora/index.js +3936 -0
- package/dist/compiled/ora/index.js.LICENSE.txt +1 -0
- package/dist/compiled/ora/license +9 -0
- package/dist/compiled/ora/package.json +1 -0
- package/dist/compiled/pkg-up/index.d.ts +48 -0
- package/dist/compiled/pkg-up/index.js +15 -0
- package/dist/compiled/pkg-up/license +9 -0
- package/dist/compiled/pkg-up/package.json +1 -0
- package/dist/compiled/semver/classes/comparator.d.ts +17 -0
- package/dist/compiled/semver/classes/range.d.ts +21 -0
- package/dist/compiled/semver/classes/semver.d.ts +62 -0
- package/dist/compiled/semver/functions/clean.d.ts +8 -0
- package/dist/compiled/semver/functions/cmp.d.ts +16 -0
- package/dist/compiled/semver/functions/coerce.d.ts +12 -0
- package/dist/compiled/semver/functions/compare-build.d.ts +16 -0
- package/dist/compiled/semver/functions/compare-loose.d.ts +5 -0
- package/dist/compiled/semver/functions/compare.d.ts +20 -0
- package/dist/compiled/semver/functions/diff.d.ts +13 -0
- package/dist/compiled/semver/functions/eq.d.ts +9 -0
- package/dist/compiled/semver/functions/gt.d.ts +9 -0
- package/dist/compiled/semver/functions/gte.d.ts +9 -0
- package/dist/compiled/semver/functions/inc.d.ts +15 -0
- package/dist/compiled/semver/functions/lt.d.ts +9 -0
- package/dist/compiled/semver/functions/lte.d.ts +8 -0
- package/dist/compiled/semver/functions/major.d.ts +9 -0
- package/dist/compiled/semver/functions/minor.d.ts +9 -0
- package/dist/compiled/semver/functions/neq.d.ts +9 -0
- package/dist/compiled/semver/functions/parse.d.ts +12 -0
- package/dist/compiled/semver/functions/patch.d.ts +9 -0
- package/dist/compiled/semver/functions/prerelease.d.ts +12 -0
- package/dist/compiled/semver/functions/rcompare.d.ts +15 -0
- package/dist/compiled/semver/functions/rsort.d.ts +9 -0
- package/dist/compiled/semver/functions/satisfies.d.ts +14 -0
- package/dist/compiled/semver/functions/sort.d.ts +9 -0
- package/dist/compiled/semver/functions/valid.d.ts +11 -0
- package/dist/compiled/semver/index.d.ts +133 -0
- package/dist/compiled/semver/index.js +1779 -0
- package/dist/compiled/semver/internals/identifiers.d.ts +13 -0
- package/dist/compiled/semver/license +15 -0
- package/dist/compiled/semver/package.json +1 -0
- package/dist/compiled/semver/ranges/gtr.d.ts +14 -0
- package/dist/compiled/semver/ranges/intersects.d.ts +13 -0
- package/dist/compiled/semver/ranges/ltr.d.ts +14 -0
- package/dist/compiled/semver/ranges/max-satisfying.d.ts +14 -0
- package/dist/compiled/semver/ranges/min-satisfying.d.ts +14 -0
- package/dist/compiled/semver/ranges/min-version.d.ts +10 -0
- package/dist/compiled/semver/ranges/outside.d.ts +15 -0
- package/dist/compiled/semver/ranges/simplify.d.ts +14 -0
- package/dist/compiled/semver/ranges/subset.d.ts +13 -0
- package/dist/compiled/semver/ranges/to-comparators.d.ts +9 -0
- package/dist/compiled/semver/ranges/valid.d.ts +12 -0
- package/dist/compiled/signale/index.d.ts +162 -0
- package/dist/compiled/signale/index.js +1704 -0
- package/dist/compiled/signale/package.json +1 -0
- package/dist/compiled/slash/index.d.ts +25 -0
- package/dist/compiled/slash/index.js +32 -0
- package/dist/compiled/slash/license +9 -0
- package/dist/compiled/slash/package.json +1 -0
- package/dist/compiled/strip-ansi/index.d.ts +17 -0
- package/dist/compiled/strip-ansi/index.js +34 -0
- package/dist/compiled/strip-ansi/license +9 -0
- package/dist/compiled/strip-ansi/package.json +1 -0
- package/dist/compiled/tsconfig-paths/index.js +629 -0
- package/dist/compiled/tsconfig-paths/index.mjs +2 -0
- package/dist/compiled/tsconfig-paths/lib/config-loader.d.ts +33 -0
- package/dist/compiled/tsconfig-paths/lib/filesystem.d.ts +34 -0
- package/dist/compiled/tsconfig-paths/lib/index.d.ts +5 -0
- package/dist/compiled/tsconfig-paths/lib/mapping-entry.d.ts +18 -0
- package/dist/compiled/tsconfig-paths/lib/match-path-async.d.ts +21 -0
- package/dist/compiled/tsconfig-paths/lib/match-path-sync.d.ts +32 -0
- package/dist/compiled/tsconfig-paths/lib/register.d.ts +12 -0
- package/dist/compiled/tsconfig-paths/lib/try-path.d.ts +15 -0
- package/dist/compiled/tsconfig-paths/lib/tsconfig-loader.d.ts +28 -0
- package/dist/compiled/tsconfig-paths/license +21 -0
- package/dist/compiled/tsconfig-paths/package.json +1 -0
- package/dist/compiled/upath/index.js +135 -0
- package/dist/compiled/upath/license +22 -0
- package/dist/compiled/upath/package.json +1 -0
- package/dist/compiled/upath/upath.d.ts +241 -0
- package/dist/compiled/url-join/index.d.ts +17 -0
- package/dist/compiled/url-join/index.js +61 -0
- package/dist/compiled/url-join/license +21 -0
- package/dist/compiled/url-join/package.json +1 -0
- package/dist/compiled/webpack-chain/index.js +1475 -0
- package/dist/compiled/webpack-chain/license +373 -0
- package/dist/compiled/webpack-chain/package.json +1 -0
- package/dist/compiled/webpack-chain/types/index.d.ts +599 -0
- package/dist/esm/cli/alias.mjs +31 -0
- package/dist/esm/cli/applyOptionsChain.mjs +16 -0
- package/dist/esm/cli/commands.mjs +23 -0
- package/dist/esm/cli/common.mjs +9 -0
- package/dist/esm/cli/config.mjs +5 -0
- package/dist/esm/cli/constants.mjs +30 -0
- package/dist/esm/cli/ensure.mjs +9 -0
- package/dist/esm/cli/fs.mjs +9 -0
- package/dist/esm/cli/get/config.mjs +14 -0
- package/dist/esm/cli/get/data.mjs +49 -0
- package/dist/esm/cli/get/index.mjs +18 -0
- package/dist/esm/cli/index.mjs +23 -0
- package/dist/esm/cli/is/config.mjs +37 -0
- package/dist/esm/cli/is/env.mjs +6 -0
- package/dist/esm/cli/is/index.mjs +4 -0
- package/dist/esm/cli/is/project.mjs +75 -0
- package/dist/esm/cli/is/type.mjs +26 -0
- package/dist/esm/cli/logger.mjs +1 -0
- package/dist/esm/cli/modulePath.mjs +33 -0
- package/dist/esm/cli/monorepo.mjs +50 -0
- package/dist/esm/cli/package.mjs +51 -0
- package/dist/esm/cli/path.mjs +35 -0
- package/dist/esm/cli/port.mjs +35 -0
- package/dist/esm/cli/prettyInstructions.mjs +70 -0
- package/dist/esm/cli/require.mjs +79 -0
- package/dist/esm/cli/route.mjs +36 -0
- package/dist/esm/cli/runtimeExports.mjs +42 -0
- package/dist/esm/cli/tsconfig.mjs +7 -0
- package/dist/esm/cli/version.mjs +24 -0
- package/dist/esm/cli/watch.mjs +40 -0
- package/dist/esm/compiled.mjs +45 -0
- package/dist/esm/import.mjs +9 -0
- package/dist/esm/index.mjs +3 -0
- package/dist/esm/rslib-runtime.mjs +12 -0
- package/dist/esm/universal/constants.mjs +14 -0
- package/dist/esm/universal/index.mjs +1 -0
- package/dist/esm/universal/path.mjs +2 -0
- package/dist/esm/universal/pluginDagSort.mjs +41 -0
- package/dist/esm-node/cli/alias.mjs +32 -0
- package/dist/esm-node/cli/applyOptionsChain.mjs +17 -0
- package/dist/esm-node/cli/commands.mjs +24 -0
- package/dist/esm-node/cli/common.mjs +10 -0
- package/dist/esm-node/cli/config.mjs +6 -0
- package/dist/esm-node/cli/constants.mjs +31 -0
- package/dist/esm-node/cli/ensure.mjs +10 -0
- package/dist/esm-node/cli/fs.mjs +10 -0
- package/dist/esm-node/cli/get/config.mjs +15 -0
- package/dist/esm-node/cli/get/data.mjs +50 -0
- package/dist/esm-node/cli/get/index.mjs +19 -0
- package/dist/esm-node/cli/index.mjs +24 -0
- package/dist/esm-node/cli/is/config.mjs +38 -0
- package/dist/esm-node/cli/is/env.mjs +7 -0
- package/dist/esm-node/cli/is/index.mjs +5 -0
- package/dist/esm-node/cli/is/project.mjs +76 -0
- package/dist/esm-node/cli/is/type.mjs +27 -0
- package/dist/esm-node/cli/logger.mjs +2 -0
- package/dist/esm-node/cli/modulePath.mjs +34 -0
- package/dist/esm-node/cli/monorepo.mjs +51 -0
- package/dist/esm-node/cli/package.mjs +52 -0
- package/dist/esm-node/cli/path.mjs +36 -0
- package/dist/esm-node/cli/port.mjs +36 -0
- package/dist/esm-node/cli/prettyInstructions.mjs +71 -0
- package/dist/esm-node/cli/require.mjs +80 -0
- package/dist/esm-node/cli/route.mjs +37 -0
- package/dist/esm-node/cli/runtimeExports.mjs +43 -0
- package/dist/esm-node/cli/tsconfig.mjs +8 -0
- package/dist/esm-node/cli/version.mjs +25 -0
- package/dist/esm-node/cli/watch.mjs +41 -0
- package/dist/esm-node/compiled.mjs +45 -0
- package/dist/esm-node/import.mjs +10 -0
- package/dist/esm-node/index.mjs +4 -0
- package/dist/esm-node/universal/constants.mjs +15 -0
- package/dist/esm-node/universal/index.mjs +2 -0
- package/dist/esm-node/universal/path.mjs +3 -0
- package/dist/esm-node/universal/pluginDagSort.mjs +42 -0
- package/dist/types/cli/alias.d.ts +20 -0
- package/dist/types/cli/applyOptionsChain.d.ts +3 -0
- package/dist/types/cli/commands.d.ts +8 -0
- package/dist/types/cli/common.d.ts +9 -0
- package/dist/types/cli/config.d.ts +4 -0
- package/dist/types/cli/constants.d.ts +55 -0
- package/dist/types/cli/ensure.d.ts +8 -0
- package/dist/types/cli/fs.d.ts +7 -0
- package/dist/types/cli/get/config.d.ts +1 -0
- package/dist/types/cli/get/data.d.ts +6 -0
- package/dist/types/cli/get/index.d.ts +11 -0
- package/dist/types/cli/index.d.ts +23 -0
- package/dist/types/cli/is/config.d.ts +22 -0
- package/dist/types/cli/is/env.d.ts +8 -0
- package/dist/types/cli/is/index.d.ts +4 -0
- package/dist/types/cli/is/project.d.ts +39 -0
- package/dist/types/cli/is/type.d.ts +15 -0
- package/dist/types/cli/logger.d.ts +1 -0
- package/dist/types/cli/modulePath.d.ts +5 -0
- package/dist/types/cli/monorepo.d.ts +9 -0
- package/dist/types/cli/package.d.ts +5 -0
- package/dist/types/cli/path.d.ts +11 -0
- package/dist/types/cli/port.d.ts +12 -0
- package/dist/types/cli/prettyInstructions.d.ts +9 -0
- package/dist/types/cli/require.d.ts +9 -0
- package/dist/types/cli/route.d.ts +4 -0
- package/dist/types/cli/runtimeExports.d.ts +5 -0
- package/dist/types/cli/tsconfig.d.ts +1 -0
- package/dist/types/cli/version.d.ts +4 -0
- package/dist/types/cli/watch.d.ts +8 -0
- package/dist/types/compiled.d.ts +37 -0
- package/dist/types/import.d.ts +5 -0
- package/dist/types/index.d.ts +3 -0
- package/dist/types/universal/constants.d.ts +47 -0
- package/dist/types/universal/index.d.ts +1 -0
- package/dist/types/universal/path.d.ts +1 -0
- package/dist/types/universal/pluginDagSort.d.ts +1 -0
- package/package.json +174 -0
- package/rslib.config.mts +162 -0
- package/rstest.config.mts +8 -0
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.n = (module)=>{
|
|
5
|
+
var getter = module && module.__esModule ? ()=>module['default'] : ()=>module;
|
|
6
|
+
__webpack_require__.d(getter, {
|
|
7
|
+
a: getter
|
|
8
|
+
});
|
|
9
|
+
return getter;
|
|
10
|
+
};
|
|
11
|
+
})();
|
|
12
|
+
(()=>{
|
|
13
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
14
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: definition[key]
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
})();
|
|
20
|
+
(()=>{
|
|
21
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
22
|
+
})();
|
|
23
|
+
(()=>{
|
|
24
|
+
__webpack_require__.r = (exports1)=>{
|
|
25
|
+
if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
26
|
+
value: 'Module'
|
|
27
|
+
});
|
|
28
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
29
|
+
value: true
|
|
30
|
+
});
|
|
31
|
+
};
|
|
32
|
+
})();
|
|
33
|
+
var __webpack_exports__ = {};
|
|
34
|
+
__webpack_require__.r(__webpack_exports__);
|
|
35
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
36
|
+
getPort: ()=>getPort
|
|
37
|
+
});
|
|
38
|
+
const external_net_namespaceObject = require("net");
|
|
39
|
+
var external_net_default = /*#__PURE__*/ __webpack_require__.n(external_net_namespaceObject);
|
|
40
|
+
const external_compiled_js_namespaceObject = require("../compiled.js");
|
|
41
|
+
const external_logger_js_namespaceObject = require("./logger.js");
|
|
42
|
+
const getPort = async (expectPort, { tryLimits = 20, strictPort = false, slient = false } = {})=>{
|
|
43
|
+
let port = expectPort;
|
|
44
|
+
if ('string' == typeof port) port = parseInt(port, 10);
|
|
45
|
+
if (strictPort) tryLimits = 1;
|
|
46
|
+
const original = port;
|
|
47
|
+
let found = false;
|
|
48
|
+
let attempts = 0;
|
|
49
|
+
while(!found && attempts <= tryLimits)try {
|
|
50
|
+
await new Promise((resolve, reject)=>{
|
|
51
|
+
const server = external_net_default().createServer();
|
|
52
|
+
server.unref();
|
|
53
|
+
server.on('error', reject);
|
|
54
|
+
server.listen({
|
|
55
|
+
port,
|
|
56
|
+
host: '0.0.0.0'
|
|
57
|
+
}, ()=>{
|
|
58
|
+
found = true;
|
|
59
|
+
server.close(resolve);
|
|
60
|
+
});
|
|
61
|
+
});
|
|
62
|
+
} catch (e) {
|
|
63
|
+
if ('EADDRINUSE' !== e.code) throw e;
|
|
64
|
+
port++;
|
|
65
|
+
attempts++;
|
|
66
|
+
}
|
|
67
|
+
if (port !== original) {
|
|
68
|
+
if (strictPort) throw new Error(`Port "${original}" is occupied, please choose another one.`);
|
|
69
|
+
else if (!slient) external_logger_js_namespaceObject.logger.info(`Port ${original} is in use. ${external_compiled_js_namespaceObject.chalk.yellow(`using port ${port}.`)}`);
|
|
70
|
+
}
|
|
71
|
+
return port;
|
|
72
|
+
};
|
|
73
|
+
exports.getPort = __webpack_exports__.getPort;
|
|
74
|
+
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
75
|
+
"getPort"
|
|
76
|
+
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
77
|
+
Object.defineProperty(exports, '__esModule', {
|
|
78
|
+
value: true
|
|
79
|
+
});
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.n = (module)=>{
|
|
5
|
+
var getter = module && module.__esModule ? ()=>module['default'] : ()=>module;
|
|
6
|
+
__webpack_require__.d(getter, {
|
|
7
|
+
a: getter
|
|
8
|
+
});
|
|
9
|
+
return getter;
|
|
10
|
+
};
|
|
11
|
+
})();
|
|
12
|
+
(()=>{
|
|
13
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
14
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: definition[key]
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
})();
|
|
20
|
+
(()=>{
|
|
21
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
22
|
+
})();
|
|
23
|
+
(()=>{
|
|
24
|
+
__webpack_require__.r = (exports1)=>{
|
|
25
|
+
if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
26
|
+
value: 'Module'
|
|
27
|
+
});
|
|
28
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
29
|
+
value: true
|
|
30
|
+
});
|
|
31
|
+
};
|
|
32
|
+
})();
|
|
33
|
+
var __webpack_exports__ = {};
|
|
34
|
+
__webpack_require__.r(__webpack_exports__);
|
|
35
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
36
|
+
getAddressUrls: ()=>getAddressUrls,
|
|
37
|
+
prettyInstructions: ()=>prettyInstructions
|
|
38
|
+
});
|
|
39
|
+
const external_net_namespaceObject = require("net");
|
|
40
|
+
const external_os_namespaceObject = require("os");
|
|
41
|
+
var external_os_default = /*#__PURE__*/ __webpack_require__.n(external_os_namespaceObject);
|
|
42
|
+
const external_compiled_js_namespaceObject = require("../compiled.js");
|
|
43
|
+
const external_constants_js_namespaceObject = require("./constants.js");
|
|
44
|
+
const index_js_namespaceObject = require("./is/index.js");
|
|
45
|
+
const normalizeUrl = (url)=>url.replace(/([^:]\/)\/+/g, '$1');
|
|
46
|
+
const getIpv4Interfaces = ()=>{
|
|
47
|
+
const interfaces = external_os_default().networkInterfaces();
|
|
48
|
+
const ipv4Interfaces = [];
|
|
49
|
+
Object.keys(interfaces).forEach((key)=>{
|
|
50
|
+
interfaces[key].forEach((detail)=>{
|
|
51
|
+
const familyV4Value = 'string' == typeof detail.family ? 'IPv4' : 4;
|
|
52
|
+
if (detail.family === familyV4Value) ipv4Interfaces.push(detail);
|
|
53
|
+
});
|
|
54
|
+
});
|
|
55
|
+
return ipv4Interfaces;
|
|
56
|
+
};
|
|
57
|
+
const getHostInUrl = (host)=>{
|
|
58
|
+
if ((0, external_net_namespaceObject.isIPv6)(host)) return '::' === host ? '[::1]' : `[${host}]`;
|
|
59
|
+
return host;
|
|
60
|
+
};
|
|
61
|
+
const getAddressUrls = (protocol = 'http', port, host)=>{
|
|
62
|
+
const LOCAL_LABEL = 'Local: ';
|
|
63
|
+
const NETWORK_LABEL = 'Network: ';
|
|
64
|
+
const isLocalhost = (url)=>url?.includes('localhost');
|
|
65
|
+
if (host && host !== external_constants_js_namespaceObject.DEFAULT_DEV_HOST) return [
|
|
66
|
+
{
|
|
67
|
+
label: isLocalhost(host) ? LOCAL_LABEL : NETWORK_LABEL,
|
|
68
|
+
url: `${protocol}://${getHostInUrl(host)}:${port}`
|
|
69
|
+
}
|
|
70
|
+
];
|
|
71
|
+
const ipv4Interfaces = getIpv4Interfaces();
|
|
72
|
+
return ipv4Interfaces.reduce((memo, detail)=>{
|
|
73
|
+
if (isLocalhost(detail.address) || detail.internal) memo.push({
|
|
74
|
+
label: LOCAL_LABEL,
|
|
75
|
+
url: `${protocol}://localhost:${port}`
|
|
76
|
+
});
|
|
77
|
+
else memo.push({
|
|
78
|
+
label: NETWORK_LABEL,
|
|
79
|
+
url: `${protocol}://${detail.address}:${port}`
|
|
80
|
+
});
|
|
81
|
+
return memo;
|
|
82
|
+
}, []);
|
|
83
|
+
};
|
|
84
|
+
const prettyInstructions = (appContext, config)=>{
|
|
85
|
+
const { entrypoints, serverRoutes, port, apiOnly, checkedEntries } = appContext;
|
|
86
|
+
const isHttps = (0, index_js_namespaceObject.isDev)() && (config?.dev?.https || config?.tools?.devServer?.https);
|
|
87
|
+
const urls = getAddressUrls(isHttps ? 'https' : 'http', port, config.dev?.host);
|
|
88
|
+
const routes = apiOnly ? serverRoutes : serverRoutes.filter((route)=>route.entryName);
|
|
89
|
+
let message = '\n';
|
|
90
|
+
if ((0, index_js_namespaceObject.isSingleEntry)(entrypoints, config.source?.mainEntryName) || apiOnly) {
|
|
91
|
+
const defaultRoutePath = routes[0]?.urlPath ?? '';
|
|
92
|
+
message += urls.map(({ label, url })=>` ${external_compiled_js_namespaceObject.chalk.bold(`> ${label.padEnd(10)}`)}${external_compiled_js_namespaceObject.chalk.cyanBright(normalizeUrl(`${url}/${defaultRoutePath}`))}\n`).join('');
|
|
93
|
+
} else {
|
|
94
|
+
const maxNameLength = Math.max(...routes.map((r)=>r.entryName.length));
|
|
95
|
+
urls.forEach(({ label, url })=>{
|
|
96
|
+
message += ` ${external_compiled_js_namespaceObject.chalk.bold(`> ${label}`)}${0 === routes.length ? external_compiled_js_namespaceObject.chalk.cyanBright(url) : ''}\n`;
|
|
97
|
+
routes.forEach(({ entryName, urlPath, isSSR })=>{
|
|
98
|
+
if (!checkedEntries.includes(entryName)) return;
|
|
99
|
+
message += ` ${external_compiled_js_namespaceObject.chalk.yellowBright(isSSR ? 'λ' : '○')} ${external_compiled_js_namespaceObject.chalk.yellowBright(entryName.padEnd(maxNameLength + 8))}${external_compiled_js_namespaceObject.chalk.cyanBright(normalizeUrl(`${url}/${urlPath}`))}\n`;
|
|
100
|
+
});
|
|
101
|
+
});
|
|
102
|
+
message += '\n';
|
|
103
|
+
message += external_compiled_js_namespaceObject.chalk.cyanBright(' λ (Server) server-side renders at runtime\n');
|
|
104
|
+
message += external_compiled_js_namespaceObject.chalk.cyanBright(' ○ (Static) client-side renders as static HTML\n');
|
|
105
|
+
}
|
|
106
|
+
if (config.dev?.cliShortcuts) message += ` ${external_compiled_js_namespaceObject.chalk.dim('> press')} ${external_compiled_js_namespaceObject.chalk.bold('h + enter')} ${external_compiled_js_namespaceObject.chalk.dim('to show shortcuts')}\n`;
|
|
107
|
+
return message;
|
|
108
|
+
};
|
|
109
|
+
exports.getAddressUrls = __webpack_exports__.getAddressUrls;
|
|
110
|
+
exports.prettyInstructions = __webpack_exports__.prettyInstructions;
|
|
111
|
+
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
112
|
+
"getAddressUrls",
|
|
113
|
+
"prettyInstructions"
|
|
114
|
+
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
115
|
+
Object.defineProperty(exports, '__esModule', {
|
|
116
|
+
value: true
|
|
117
|
+
});
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
+
})();
|
|
14
|
+
(()=>{
|
|
15
|
+
__webpack_require__.r = (exports1)=>{
|
|
16
|
+
if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
+
value: 'Module'
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
+
value: true
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
})();
|
|
24
|
+
var __webpack_exports__ = {};
|
|
25
|
+
__webpack_require__.r(__webpack_exports__);
|
|
26
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
cleanRequireCache: ()=>cleanRequireCache,
|
|
28
|
+
compatibleRequire: ()=>compatibleRequire,
|
|
29
|
+
dynamicImport: ()=>dynamicImport,
|
|
30
|
+
loadFromProject: ()=>loadFromProject,
|
|
31
|
+
requireExistModule: ()=>requireExistModule,
|
|
32
|
+
tryResolve: ()=>tryResolve
|
|
33
|
+
});
|
|
34
|
+
const promises_namespaceObject = require("node:fs/promises");
|
|
35
|
+
const external_node_path_namespaceObject = require("node:path");
|
|
36
|
+
const external_node_url_namespaceObject = require("node:url");
|
|
37
|
+
const external_fs_js_namespaceObject = require("./fs.js");
|
|
38
|
+
async function importPath(path) {
|
|
39
|
+
const modulePath = (0, external_node_path_namespaceObject.isAbsolute)(path) ? (0, external_node_url_namespaceObject.pathToFileURL)(path).href : path;
|
|
40
|
+
if ('development' !== process.env.NODE_ENV) return await import(modulePath);
|
|
41
|
+
{
|
|
42
|
+
const timestamp = Date.now();
|
|
43
|
+
return await import(`${modulePath}?t=${timestamp}`);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
async function compatibleRequireESM(path, interop = true) {
|
|
47
|
+
if (path.endsWith('.json')) return JSON.parse(await (0, promises_namespaceObject.readFile)(path, 'utf8'));
|
|
48
|
+
const requiredModule = await importPath(path);
|
|
49
|
+
return interop ? requiredModule.default : requiredModule;
|
|
50
|
+
}
|
|
51
|
+
async function compatibleRequireCJS(path, interop = true) {
|
|
52
|
+
if (path.endsWith('.json')) return require(path);
|
|
53
|
+
try {
|
|
54
|
+
const requiredModule = require(path);
|
|
55
|
+
return interop && requiredModule?.__esModule ? requiredModule.default : requiredModule;
|
|
56
|
+
} catch (err) {
|
|
57
|
+
if ('ERR_REQUIRE_ESM' === err.code) return await compatibleRequireESM(path, interop);
|
|
58
|
+
throw err;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
async function compatibleRequire(path, interop = true) {
|
|
62
|
+
return await compatibleRequireCJS(path, interop);
|
|
63
|
+
}
|
|
64
|
+
async function loadFromProject(moduleName, appDir) {
|
|
65
|
+
let requiredModule;
|
|
66
|
+
const paths = [
|
|
67
|
+
appDir,
|
|
68
|
+
process.cwd()
|
|
69
|
+
];
|
|
70
|
+
try {
|
|
71
|
+
const modulePath = tryResolve(moduleName, ...paths);
|
|
72
|
+
requiredModule = require(modulePath);
|
|
73
|
+
return requiredModule.default || requiredModule;
|
|
74
|
+
} catch (error) {
|
|
75
|
+
if ('MODULE_NOT_FOUND' === error.code) throw new Error(`Cannot find module ${moduleName}.`);
|
|
76
|
+
throw error;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
const dynamicImport = new Function('modulePath', 'return import(modulePath)');
|
|
80
|
+
const requireExistModule = async (filename, opt)=>{
|
|
81
|
+
const final = {
|
|
82
|
+
extensions: [
|
|
83
|
+
'.ts',
|
|
84
|
+
'.js'
|
|
85
|
+
],
|
|
86
|
+
interop: true,
|
|
87
|
+
...opt
|
|
88
|
+
};
|
|
89
|
+
const exist = (0, external_fs_js_namespaceObject.findExists)(final.extensions.map((ext)=>`${filename}${ext}`));
|
|
90
|
+
if (!exist) return null;
|
|
91
|
+
return compatibleRequire(exist, final.interop);
|
|
92
|
+
};
|
|
93
|
+
const cleanRequireCache = (filelist)=>{
|
|
94
|
+
filelist.forEach((filepath)=>{
|
|
95
|
+
if (require.cache) delete require.cache[filepath];
|
|
96
|
+
});
|
|
97
|
+
};
|
|
98
|
+
const tryResolve = (name, ...resolvePath)=>{
|
|
99
|
+
let filePath = '';
|
|
100
|
+
try {
|
|
101
|
+
filePath = require.resolve(name, {
|
|
102
|
+
paths: resolvePath
|
|
103
|
+
});
|
|
104
|
+
delete require.cache[filePath];
|
|
105
|
+
} catch (err) {
|
|
106
|
+
if ('MODULE_NOT_FOUND' === err.code) throw new Error(`Can not find module ${name}.`);
|
|
107
|
+
throw err;
|
|
108
|
+
}
|
|
109
|
+
return filePath;
|
|
110
|
+
};
|
|
111
|
+
exports.cleanRequireCache = __webpack_exports__.cleanRequireCache;
|
|
112
|
+
exports.compatibleRequire = __webpack_exports__.compatibleRequire;
|
|
113
|
+
exports.dynamicImport = __webpack_exports__.dynamicImport;
|
|
114
|
+
exports.loadFromProject = __webpack_exports__.loadFromProject;
|
|
115
|
+
exports.requireExistModule = __webpack_exports__.requireExistModule;
|
|
116
|
+
exports.tryResolve = __webpack_exports__.tryResolve;
|
|
117
|
+
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
118
|
+
"cleanRequireCache",
|
|
119
|
+
"compatibleRequire",
|
|
120
|
+
"dynamicImport",
|
|
121
|
+
"loadFromProject",
|
|
122
|
+
"requireExistModule",
|
|
123
|
+
"tryResolve"
|
|
124
|
+
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
125
|
+
Object.defineProperty(exports, '__esModule', {
|
|
126
|
+
value: true
|
|
127
|
+
});
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
+
})();
|
|
14
|
+
(()=>{
|
|
15
|
+
__webpack_require__.r = (exports1)=>{
|
|
16
|
+
if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
+
value: 'Module'
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
+
value: true
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
})();
|
|
24
|
+
var __webpack_exports__ = {};
|
|
25
|
+
__webpack_require__.r(__webpack_exports__);
|
|
26
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
filterRoutesForServer: ()=>filterRoutesForServer,
|
|
28
|
+
filterRoutesLoader: ()=>filterRoutesLoader,
|
|
29
|
+
markRoutes: ()=>markRoutes
|
|
30
|
+
});
|
|
31
|
+
const external_compiled_js_namespaceObject = require("../compiled.js");
|
|
32
|
+
const { cloneDeep } = external_compiled_js_namespaceObject.lodash;
|
|
33
|
+
function filterRoutesForServer(routes) {
|
|
34
|
+
const clonedRoutes = cloneDeep(routes);
|
|
35
|
+
const newRoutes = clonedRoutes.map((route)=>{
|
|
36
|
+
if ('nested' !== route.type) return route;
|
|
37
|
+
if (route.children && route.children.length > 0) route.children = filterRoutesForServer(route.children);
|
|
38
|
+
if (route.inValidSSRRoute) return null;
|
|
39
|
+
return route;
|
|
40
|
+
}).filter((route)=>null !== route);
|
|
41
|
+
return newRoutes;
|
|
42
|
+
}
|
|
43
|
+
function filterRoutesLoader(routes) {
|
|
44
|
+
const clonedRoutes = cloneDeep(routes);
|
|
45
|
+
const newRoutes = clonedRoutes.map((route)=>{
|
|
46
|
+
if ('nested' !== route.type) return route;
|
|
47
|
+
if (route.children && route.children.length > 0) route.children = filterRoutesLoader(route.children);
|
|
48
|
+
if (route.inValidSSRRoute) {
|
|
49
|
+
delete route.loader;
|
|
50
|
+
delete route.data;
|
|
51
|
+
delete route.action;
|
|
52
|
+
}
|
|
53
|
+
return route;
|
|
54
|
+
}).filter((route)=>null !== route);
|
|
55
|
+
return newRoutes;
|
|
56
|
+
}
|
|
57
|
+
function markRoutes(routes, routeIds) {
|
|
58
|
+
return routes.map((route)=>{
|
|
59
|
+
if ('nested' !== route.type) return route;
|
|
60
|
+
if (route.children && route.children.length > 0) route.children = markRoutes(route.children, routeIds);
|
|
61
|
+
if (route.children && route.children.length > 0) route.inValidSSRRoute = route.children.every((child)=>child.inValidSSRRoute ?? false);
|
|
62
|
+
else if (route.id) route.inValidSSRRoute = !routeIds.includes(route.id);
|
|
63
|
+
return route;
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
exports.filterRoutesForServer = __webpack_exports__.filterRoutesForServer;
|
|
67
|
+
exports.filterRoutesLoader = __webpack_exports__.filterRoutesLoader;
|
|
68
|
+
exports.markRoutes = __webpack_exports__.markRoutes;
|
|
69
|
+
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
70
|
+
"filterRoutesForServer",
|
|
71
|
+
"filterRoutesLoader",
|
|
72
|
+
"markRoutes"
|
|
73
|
+
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
74
|
+
Object.defineProperty(exports, '__esModule', {
|
|
75
|
+
value: true
|
|
76
|
+
});
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.n = (module)=>{
|
|
5
|
+
var getter = module && module.__esModule ? ()=>module['default'] : ()=>module;
|
|
6
|
+
__webpack_require__.d(getter, {
|
|
7
|
+
a: getter
|
|
8
|
+
});
|
|
9
|
+
return getter;
|
|
10
|
+
};
|
|
11
|
+
})();
|
|
12
|
+
(()=>{
|
|
13
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
14
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: definition[key]
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
})();
|
|
20
|
+
(()=>{
|
|
21
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
22
|
+
})();
|
|
23
|
+
(()=>{
|
|
24
|
+
__webpack_require__.r = (exports1)=>{
|
|
25
|
+
if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
26
|
+
value: 'Module'
|
|
27
|
+
});
|
|
28
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
29
|
+
value: true
|
|
30
|
+
});
|
|
31
|
+
};
|
|
32
|
+
})();
|
|
33
|
+
var __webpack_exports__ = {};
|
|
34
|
+
__webpack_require__.r(__webpack_exports__);
|
|
35
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
36
|
+
createRuntimeExportsUtils: ()=>createRuntimeExportsUtils
|
|
37
|
+
});
|
|
38
|
+
const external_path_namespaceObject = require("path");
|
|
39
|
+
var external_path_default = /*#__PURE__*/ __webpack_require__.n(external_path_namespaceObject);
|
|
40
|
+
const external_compiled_js_namespaceObject = require("../compiled.js");
|
|
41
|
+
const external_path_js_namespaceObject = require("./path.js");
|
|
42
|
+
const memo = (fn)=>{
|
|
43
|
+
const cache = new Map();
|
|
44
|
+
return (...params)=>{
|
|
45
|
+
const stringifiedParams = JSON.stringify(params);
|
|
46
|
+
const cachedResult = cache.get(stringifiedParams);
|
|
47
|
+
if (cachedResult) return cachedResult;
|
|
48
|
+
const res = fn(...params);
|
|
49
|
+
cache.set(stringifiedParams, res);
|
|
50
|
+
return res;
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
const ensureRuntimeExportsFile = (filepath)=>{
|
|
54
|
+
external_compiled_js_namespaceObject.fs.ensureDirSync(external_path_default().dirname(filepath));
|
|
55
|
+
if (!external_compiled_js_namespaceObject.fs.existsSync(filepath)) external_compiled_js_namespaceObject.fs.writeFileSync(filepath, 'export {};\n');
|
|
56
|
+
};
|
|
57
|
+
const formatRuntimeExports = (exportsList)=>{
|
|
58
|
+
if (0 === exportsList.length) return 'export {};\n';
|
|
59
|
+
return `${exportsList.join('\n')}\n`;
|
|
60
|
+
};
|
|
61
|
+
const flushRuntimeExports = (filepath, exportsSet)=>{
|
|
62
|
+
external_compiled_js_namespaceObject.fs.writeFileSync(filepath, formatRuntimeExports(Array.from(exportsSet)));
|
|
63
|
+
};
|
|
64
|
+
const createRuntimeExportsUtils = memo((internalDirectory, filename)=>{
|
|
65
|
+
const filepath = external_path_default().resolve(internalDirectory, `${filename}.ts`);
|
|
66
|
+
const exportsSet = new Set();
|
|
67
|
+
ensureRuntimeExportsFile(filepath);
|
|
68
|
+
return {
|
|
69
|
+
addExport (exportStatement) {
|
|
70
|
+
const normalized = exportStatement?.trim();
|
|
71
|
+
if (!normalized) return;
|
|
72
|
+
exportsSet.add(normalized);
|
|
73
|
+
flushRuntimeExports(filepath, exportsSet);
|
|
74
|
+
},
|
|
75
|
+
getPath () {
|
|
76
|
+
return (0, external_path_js_namespaceObject.normalizeOutputPath)(filepath);
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
});
|
|
80
|
+
exports.createRuntimeExportsUtils = __webpack_exports__.createRuntimeExportsUtils;
|
|
81
|
+
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
82
|
+
"createRuntimeExportsUtils"
|
|
83
|
+
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
84
|
+
Object.defineProperty(exports, '__esModule', {
|
|
85
|
+
value: true
|
|
86
|
+
});
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.n = (module)=>{
|
|
5
|
+
var getter = module && module.__esModule ? ()=>module['default'] : ()=>module;
|
|
6
|
+
__webpack_require__.d(getter, {
|
|
7
|
+
a: getter
|
|
8
|
+
});
|
|
9
|
+
return getter;
|
|
10
|
+
};
|
|
11
|
+
})();
|
|
12
|
+
(()=>{
|
|
13
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
14
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: definition[key]
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
})();
|
|
20
|
+
(()=>{
|
|
21
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
22
|
+
})();
|
|
23
|
+
(()=>{
|
|
24
|
+
__webpack_require__.r = (exports1)=>{
|
|
25
|
+
if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
26
|
+
value: 'Module'
|
|
27
|
+
});
|
|
28
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
29
|
+
value: true
|
|
30
|
+
});
|
|
31
|
+
};
|
|
32
|
+
})();
|
|
33
|
+
var __webpack_exports__ = {};
|
|
34
|
+
__webpack_require__.r(__webpack_exports__);
|
|
35
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
36
|
+
resolveServerTsconfig: ()=>resolveServerTsconfig
|
|
37
|
+
});
|
|
38
|
+
const external_path_namespaceObject = require("path");
|
|
39
|
+
var external_path_default = /*#__PURE__*/ __webpack_require__.n(external_path_namespaceObject);
|
|
40
|
+
const external_constants_js_namespaceObject = require("./constants.js");
|
|
41
|
+
const resolveServerTsconfig = (appDirectory, configuredPath)=>{
|
|
42
|
+
if (configuredPath) return external_path_default().isAbsolute(configuredPath) ? configuredPath : external_path_default().resolve(appDirectory, configuredPath);
|
|
43
|
+
return external_path_default().resolve(appDirectory, external_constants_js_namespaceObject.TS_CONFIG_FILENAME);
|
|
44
|
+
};
|
|
45
|
+
exports.resolveServerTsconfig = __webpack_exports__.resolveServerTsconfig;
|
|
46
|
+
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
47
|
+
"resolveServerTsconfig"
|
|
48
|
+
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
49
|
+
Object.defineProperty(exports, '__esModule', {
|
|
50
|
+
value: true
|
|
51
|
+
});
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
+
})();
|
|
14
|
+
(()=>{
|
|
15
|
+
__webpack_require__.r = (exports1)=>{
|
|
16
|
+
if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
+
value: 'Module'
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
+
value: true
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
})();
|
|
24
|
+
var __webpack_exports__ = {};
|
|
25
|
+
__webpack_require__.r(__webpack_exports__);
|
|
26
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
isVersionAtLeast18: ()=>isVersionAtLeast18,
|
|
28
|
+
isVersionAtLeast1819: ()=>isVersionAtLeast1819,
|
|
29
|
+
isVersionAtLeast20: ()=>isVersionAtLeast20,
|
|
30
|
+
isVersionAtLeast22: ()=>isVersionAtLeast22
|
|
31
|
+
});
|
|
32
|
+
const parseNodeVersion = ()=>{
|
|
33
|
+
const [major = 0, minor = 0] = process.versions.node.split('.').map(Number);
|
|
34
|
+
return {
|
|
35
|
+
major,
|
|
36
|
+
minor
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
function isVersionAtLeast1819() {
|
|
40
|
+
const { major, minor } = parseNodeVersion();
|
|
41
|
+
return major > 18 || 18 === major && minor >= 19;
|
|
42
|
+
}
|
|
43
|
+
function isVersionAtLeast18() {
|
|
44
|
+
const { major } = parseNodeVersion();
|
|
45
|
+
return major >= 18;
|
|
46
|
+
}
|
|
47
|
+
function isVersionAtLeast22() {
|
|
48
|
+
const { major } = parseNodeVersion();
|
|
49
|
+
return major >= 22;
|
|
50
|
+
}
|
|
51
|
+
function isVersionAtLeast20() {
|
|
52
|
+
const { major } = parseNodeVersion();
|
|
53
|
+
return major >= 20;
|
|
54
|
+
}
|
|
55
|
+
exports.isVersionAtLeast18 = __webpack_exports__.isVersionAtLeast18;
|
|
56
|
+
exports.isVersionAtLeast1819 = __webpack_exports__.isVersionAtLeast1819;
|
|
57
|
+
exports.isVersionAtLeast20 = __webpack_exports__.isVersionAtLeast20;
|
|
58
|
+
exports.isVersionAtLeast22 = __webpack_exports__.isVersionAtLeast22;
|
|
59
|
+
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
60
|
+
"isVersionAtLeast18",
|
|
61
|
+
"isVersionAtLeast1819",
|
|
62
|
+
"isVersionAtLeast20",
|
|
63
|
+
"isVersionAtLeast22"
|
|
64
|
+
].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i];
|
|
65
|
+
Object.defineProperty(exports, '__esModule', {
|
|
66
|
+
value: true
|
|
67
|
+
});
|