create-myexam-app 1.0.21 → 1.0.22
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/index.js +25 -17
- package/package.json +1 -1
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/README.md +84 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/.env +3 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/config/db.js +13 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/authController.js +115 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/employeeController.js +97 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/payrollController.js +113 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/reportController.js +35 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/middleware/authMiddleware.js +9 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/Employee.js +52 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/Payroll.js +50 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/User.js +19 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/package-lock.json +1509 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/package.json +19 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/authRoutes.js +18 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/employeeRoutes.js +19 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/payrollRoutes.js +19 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/reportRoutes.js +9 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/server.js +71 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/index.html +12 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/package-lock.json +2888 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/package.json +23 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/postcss.config.js +6 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/App.jsx +57 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/apiClient.js +16 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/authApi.js +26 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/employeeApi.js +26 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/payrollApi.js +26 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/reportApi.js +6 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Header.jsx +17 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Layout.jsx +17 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Message.jsx +15 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/ProtectedRoute.jsx +41 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Sidebar.jsx +38 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/index.css +30 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/main.jsx +13 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/DashboardPage.jsx +64 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/EmployeePage.jsx +166 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/LoginPage.jsx +73 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/PayrollPage.jsx +198 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/RecoverPasswordPage.jsx +69 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/RegisterPage.jsx +69 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/ReportsPage.jsx +113 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/tailwind.config.js +13 -0
- package/projects/EPMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/vite.config.js +9 -0
- package/projects/SCMS/frontend/node_modules/.bin/acorn +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/acorn.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/acorn.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/baseline-browser-mapping +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/baseline-browser-mapping.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/baseline-browser-mapping.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/browserslist +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/browserslist.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/browserslist.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/eslint +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/eslint.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/eslint.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/jiti +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/jiti.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/jiti.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/jsesc +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/jsesc.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/jsesc.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/json5 +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/json5.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/json5.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/nanoid +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/nanoid.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/nanoid.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/node-which +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/node-which.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/node-which.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/parser +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/parser.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/parser.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/rolldown +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/rolldown.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/rolldown.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/semver +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/semver.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/semver.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/update-browserslist-db +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/update-browserslist-db.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/update-browserslist-db.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.bin/vite +16 -0
- package/projects/SCMS/frontend/node_modules/.bin/vite.cmd +17 -0
- package/projects/SCMS/frontend/node_modules/.bin/vite.ps1 +28 -0
- package/projects/SCMS/frontend/node_modules/.package-lock.json +2401 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/_metadata.json +56 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/axios.js +3184 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/axios.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/chunk-B-1-B7_t.js +33 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/package.json +3 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react-dom.js +186 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react-dom.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react-dom_client.js +14385 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react-dom_client.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react-router-dom.js +10177 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react-router-dom.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react.js +769 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react_jsx-dev-runtime.js +205 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react_jsx-dev-runtime.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react_jsx-runtime.js +209 -0
- package/projects/SCMS/frontend/node_modules/.vite/deps/react_jsx-runtime.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/code-frame/LICENSE +22 -0
- package/projects/SCMS/frontend/node_modules/@babel/code-frame/README.md +19 -0
- package/projects/SCMS/frontend/node_modules/@babel/code-frame/lib/index.js +217 -0
- package/projects/SCMS/frontend/node_modules/@babel/code-frame/lib/index.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/code-frame/package.json +32 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/LICENSE +22 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/README.md +19 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/corejs2-built-ins.js +2 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/corejs3-shipped-proposals.js +2 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/data/corejs2-built-ins.json +2120 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/data/corejs3-shipped-proposals.json +5 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/data/native-modules.json +18 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/data/overlapping-plugins.json +38 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/data/plugin-bugfixes.json +231 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/data/plugins.json +843 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/native-modules.js +2 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/overlapping-plugins.js +2 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/package.json +40 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/plugin-bugfixes.js +2 -0
- package/projects/SCMS/frontend/node_modules/@babel/compat-data/plugins.js +2 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/LICENSE +22 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/README.md +19 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/cache-contexts.js +5 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/cache-contexts.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/caching.js +261 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/caching.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/config-chain.js +469 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/config-chain.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/config-descriptors.js +190 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/config-descriptors.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/configuration.js +290 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/configuration.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/import.cjs +6 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/import.cjs.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/index-browser.js +58 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/index-browser.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/index.js +78 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/files/index.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/full.js +312 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/full.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/index.js +87 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/index.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/item.js +67 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/item.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/partial.js +158 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/partial.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/pattern-to-regex.js +38 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/pattern-to-regex.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/plugin.js +33 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/plugin.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/printer.js +113 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/printer.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/resolve-targets-browser.js +41 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/resolve-targets-browser.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/resolve-targets.js +61 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/resolve-targets.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/util.js +31 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/config/util.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/index.js +230 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/index.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/parse.js +45 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/parse.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform-ast.js +48 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform-ast.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform-file-browser.js +23 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform-file-browser.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform-file.js +40 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform-file.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform.js +47 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/lib/transform.js.map +1 -0
- package/projects/SCMS/frontend/node_modules/@babel/core/package.json +84 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/README.md +106 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/01_Introduction.md +8 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/02_Problem_Statement.md +12 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/03_Objectives.md +17 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/04_Technologies_Used.md +23 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/05_ERD.md +60 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/06_Database_Design.md +71 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/07_System_Architecture.md +28 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/08_API_Documentation.md +43 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/09_Testing.md +43 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/10_Challenges.md +12 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/REPORT/11_Conclusion.md +8 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/.env.example +4 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/config/db.js +16 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/deliveryController.js +145 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/shipmentController.js +149 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/supplierController.js +56 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/userController.js +158 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/middleware/authMiddleware.js +9 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/Delivery.js +34 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/Shipment.js +34 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/Supplier.js +38 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/User.js +21 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/package-lock.json +1540 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/package.json +22 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/deliveryRoutes.js +11 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/shipmentRoutes.js +11 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/supplierRoutes.js +9 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/userRoutes.js +11 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/server.js +70 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/.env.example +2 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/index.html +13 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/package-lock.json +2944 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/package.json +23 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/postcss.config.js +6 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/App.jsx +72 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/apiClient.js +14 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/deliveryApi.js +17 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/shipmentApi.js +17 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/supplierApi.js +9 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/userApi.js +21 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Layout.jsx +16 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Message.jsx +15 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/PageHeader.jsx +12 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Sidebar.jsx +40 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/main.jsx +13 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/Dashboard.jsx +62 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/Delivery.jsx +212 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/Login.jsx +158 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/Logout.jsx +24 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/Reports.jsx +221 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/Shipment.jsx +212 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/Supplier.jsx +118 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/styles.css +27 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/tailwind.config.js +8 -0
- package/projects/SCMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/vite.config.js +6 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/README.md +84 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/.env +3 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/config/db.js +13 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/productController.js +29 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/reportController.js +52 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/stockTransactionController.js +128 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/userController.js +115 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/controllers/warehouseController.js +29 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/middleware/authMiddleware.js +9 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/Product.js +44 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/StockTransaction.js +33 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/User.js +19 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/models/Warehouse.js +25 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/package-lock.json +1509 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/package.json +19 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/productRoutes.js +10 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/reportRoutes.js +9 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/stockTransactionRoutes.js +17 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/userRoutes.js +18 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/routes/warehouseRoutes.js +10 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/backend-project/server.js +73 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/index.html +12 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/package-lock.json +2888 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/package.json +23 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/postcss.config.js +6 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/App.jsx +66 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/apiClient.js +16 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/productApi.js +11 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/reportApi.js +6 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/transactionApi.js +21 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/userApi.js +26 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/api/warehouseApi.js +11 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Header.jsx +17 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Layout.jsx +17 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Message.jsx +15 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/ProtectedRoute.jsx +41 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/components/Sidebar.jsx +39 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/index.css +30 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/main.jsx +13 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/DashboardPage.jsx +64 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/LoginPage.jsx +73 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/ProductPage.jsx +107 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/RecoverPasswordPage.jsx +69 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/RegisterPage.jsx +69 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/ReportsPage.jsx +152 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/TransactionPage.jsx +195 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/src/pages/WarehousePage.jsx +93 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/tailwind.config.js +13 -0
- package/projects/SHMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026/frontend-project/vite.config.js +9 -0
- package/projects/SRMS/frontend/src/pages/Reports.jsx +170 -58
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/README.md +49 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/.env +3 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/middleware/authMiddleware.js +19 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/models/Customer.js +11 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/models/Product.js +10 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/models/Sale.js +19 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/models/User.js +8 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/package-lock.json +1609 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/package.json +20 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/routes/authRoutes.js +75 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/routes/customerRoutes.js +42 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/routes/productRoutes.js +41 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/routes/reportRoutes.js +129 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/routes/saleRoutes.js +107 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/backend-project/server.js +49 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/dist/assets/index-DZxY56Bj.js +75 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/dist/assets/index-J8MKb3Fq.css +1 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/dist/index.html +13 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/index.html +12 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/package-lock.json +2029 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/package.json +21 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/App.jsx +77 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/index.css +333 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/main.jsx +10 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/pages/Customers.jsx +85 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/pages/Dashboard.jsx +75 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/pages/Login.jsx +65 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/pages/Products.jsx +91 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/pages/Register.jsx +82 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/pages/Reports.jsx +138 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/src/pages/Sales.jsx +154 -0
- package/projects/SRMS(Ely)/KALIWABO_SHEMA_ELYSEE_National_Practical_Examination_2026(/frontend-project/vite.config.js +9 -0
|
@@ -0,0 +1,469 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.buildPresetChain = buildPresetChain;
|
|
7
|
+
exports.buildPresetChainWalker = void 0;
|
|
8
|
+
exports.buildRootChain = buildRootChain;
|
|
9
|
+
function _path() {
|
|
10
|
+
const data = require("path");
|
|
11
|
+
_path = function () {
|
|
12
|
+
return data;
|
|
13
|
+
};
|
|
14
|
+
return data;
|
|
15
|
+
}
|
|
16
|
+
function _debug() {
|
|
17
|
+
const data = require("debug");
|
|
18
|
+
_debug = function () {
|
|
19
|
+
return data;
|
|
20
|
+
};
|
|
21
|
+
return data;
|
|
22
|
+
}
|
|
23
|
+
var _options = require("./validation/options.js");
|
|
24
|
+
var _patternToRegex = require("./pattern-to-regex.js");
|
|
25
|
+
var _printer = require("./printer.js");
|
|
26
|
+
var _rewriteStackTrace = require("../errors/rewrite-stack-trace.js");
|
|
27
|
+
var _configError = require("../errors/config-error.js");
|
|
28
|
+
var _index = require("./files/index.js");
|
|
29
|
+
var _caching = require("./caching.js");
|
|
30
|
+
var _configDescriptors = require("./config-descriptors.js");
|
|
31
|
+
const debug = _debug()("babel:config:config-chain");
|
|
32
|
+
function* buildPresetChain(arg, context) {
|
|
33
|
+
const chain = yield* buildPresetChainWalker(arg, context);
|
|
34
|
+
if (!chain) return null;
|
|
35
|
+
return {
|
|
36
|
+
plugins: dedupDescriptors(chain.plugins),
|
|
37
|
+
presets: dedupDescriptors(chain.presets),
|
|
38
|
+
options: chain.options.map(o => createConfigChainOptions(o)),
|
|
39
|
+
files: new Set()
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
const buildPresetChainWalker = exports.buildPresetChainWalker = makeChainWalker({
|
|
43
|
+
root: preset => loadPresetDescriptors(preset),
|
|
44
|
+
env: (preset, envName) => loadPresetEnvDescriptors(preset)(envName),
|
|
45
|
+
overrides: (preset, index) => loadPresetOverridesDescriptors(preset)(index),
|
|
46
|
+
overridesEnv: (preset, index, envName) => loadPresetOverridesEnvDescriptors(preset)(index)(envName),
|
|
47
|
+
createLogger: () => () => {}
|
|
48
|
+
});
|
|
49
|
+
const loadPresetDescriptors = (0, _caching.makeWeakCacheSync)(preset => buildRootDescriptors(preset, preset.alias, _configDescriptors.createUncachedDescriptors));
|
|
50
|
+
const loadPresetEnvDescriptors = (0, _caching.makeWeakCacheSync)(preset => (0, _caching.makeStrongCacheSync)(envName => buildEnvDescriptors(preset, preset.alias, _configDescriptors.createUncachedDescriptors, envName)));
|
|
51
|
+
const loadPresetOverridesDescriptors = (0, _caching.makeWeakCacheSync)(preset => (0, _caching.makeStrongCacheSync)(index => buildOverrideDescriptors(preset, preset.alias, _configDescriptors.createUncachedDescriptors, index)));
|
|
52
|
+
const loadPresetOverridesEnvDescriptors = (0, _caching.makeWeakCacheSync)(preset => (0, _caching.makeStrongCacheSync)(index => (0, _caching.makeStrongCacheSync)(envName => buildOverrideEnvDescriptors(preset, preset.alias, _configDescriptors.createUncachedDescriptors, index, envName))));
|
|
53
|
+
function* buildRootChain(opts, context) {
|
|
54
|
+
let configReport, babelRcReport;
|
|
55
|
+
const programmaticLogger = new _printer.ConfigPrinter();
|
|
56
|
+
const programmaticChain = yield* loadProgrammaticChain({
|
|
57
|
+
options: opts,
|
|
58
|
+
dirname: context.cwd
|
|
59
|
+
}, context, undefined, programmaticLogger);
|
|
60
|
+
if (!programmaticChain) return null;
|
|
61
|
+
const programmaticReport = yield* programmaticLogger.output();
|
|
62
|
+
let configFile;
|
|
63
|
+
if (typeof opts.configFile === "string") {
|
|
64
|
+
configFile = yield* (0, _index.loadConfig)(opts.configFile, context.cwd, context.envName, context.caller);
|
|
65
|
+
} else if (opts.configFile !== false) {
|
|
66
|
+
configFile = yield* (0, _index.findRootConfig)(context.root, context.envName, context.caller);
|
|
67
|
+
}
|
|
68
|
+
let {
|
|
69
|
+
babelrc,
|
|
70
|
+
babelrcRoots
|
|
71
|
+
} = opts;
|
|
72
|
+
let babelrcRootsDirectory = context.cwd;
|
|
73
|
+
const configFileChain = emptyChain();
|
|
74
|
+
const configFileLogger = new _printer.ConfigPrinter();
|
|
75
|
+
if (configFile) {
|
|
76
|
+
const validatedFile = validateConfigFile(configFile);
|
|
77
|
+
const result = yield* loadFileChain(validatedFile, context, undefined, configFileLogger);
|
|
78
|
+
if (!result) return null;
|
|
79
|
+
configReport = yield* configFileLogger.output();
|
|
80
|
+
if (babelrc === undefined) {
|
|
81
|
+
babelrc = validatedFile.options.babelrc;
|
|
82
|
+
}
|
|
83
|
+
if (babelrcRoots === undefined) {
|
|
84
|
+
babelrcRootsDirectory = validatedFile.dirname;
|
|
85
|
+
babelrcRoots = validatedFile.options.babelrcRoots;
|
|
86
|
+
}
|
|
87
|
+
mergeChain(configFileChain, result);
|
|
88
|
+
}
|
|
89
|
+
let ignoreFile, babelrcFile;
|
|
90
|
+
let isIgnored = false;
|
|
91
|
+
const fileChain = emptyChain();
|
|
92
|
+
if ((babelrc === true || babelrc === undefined) && typeof context.filename === "string") {
|
|
93
|
+
const pkgData = yield* (0, _index.findPackageData)(context.filename);
|
|
94
|
+
if (pkgData && babelrcLoadEnabled(context, pkgData, babelrcRoots, babelrcRootsDirectory)) {
|
|
95
|
+
({
|
|
96
|
+
ignore: ignoreFile,
|
|
97
|
+
config: babelrcFile
|
|
98
|
+
} = yield* (0, _index.findRelativeConfig)(pkgData, context.envName, context.caller));
|
|
99
|
+
if (ignoreFile) {
|
|
100
|
+
fileChain.files.add(ignoreFile.filepath);
|
|
101
|
+
}
|
|
102
|
+
if (ignoreFile && shouldIgnore(context, ignoreFile.ignore, null, ignoreFile.dirname)) {
|
|
103
|
+
isIgnored = true;
|
|
104
|
+
}
|
|
105
|
+
if (babelrcFile && !isIgnored) {
|
|
106
|
+
const validatedFile = validateBabelrcFile(babelrcFile);
|
|
107
|
+
const babelrcLogger = new _printer.ConfigPrinter();
|
|
108
|
+
const result = yield* loadFileChain(validatedFile, context, undefined, babelrcLogger);
|
|
109
|
+
if (!result) {
|
|
110
|
+
isIgnored = true;
|
|
111
|
+
} else {
|
|
112
|
+
babelRcReport = yield* babelrcLogger.output();
|
|
113
|
+
mergeChain(fileChain, result);
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
if (babelrcFile && isIgnored) {
|
|
117
|
+
fileChain.files.add(babelrcFile.filepath);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
if (context.showConfig) {
|
|
122
|
+
console.log(`Babel configs on "${context.filename}" (ascending priority):\n` + [configReport, babelRcReport, programmaticReport].filter(x => !!x).join("\n\n") + "\n-----End Babel configs-----");
|
|
123
|
+
}
|
|
124
|
+
const chain = mergeChain(mergeChain(mergeChain(emptyChain(), configFileChain), fileChain), programmaticChain);
|
|
125
|
+
return {
|
|
126
|
+
plugins: isIgnored ? [] : dedupDescriptors(chain.plugins),
|
|
127
|
+
presets: isIgnored ? [] : dedupDescriptors(chain.presets),
|
|
128
|
+
options: isIgnored ? [] : chain.options.map(o => createConfigChainOptions(o)),
|
|
129
|
+
fileHandling: isIgnored ? "ignored" : "transpile",
|
|
130
|
+
ignore: ignoreFile || undefined,
|
|
131
|
+
babelrc: babelrcFile || undefined,
|
|
132
|
+
config: configFile || undefined,
|
|
133
|
+
files: chain.files
|
|
134
|
+
};
|
|
135
|
+
}
|
|
136
|
+
function babelrcLoadEnabled(context, pkgData, babelrcRoots, babelrcRootsDirectory) {
|
|
137
|
+
if (typeof babelrcRoots === "boolean") return babelrcRoots;
|
|
138
|
+
const absoluteRoot = context.root;
|
|
139
|
+
if (babelrcRoots === undefined) {
|
|
140
|
+
return pkgData.directories.includes(absoluteRoot);
|
|
141
|
+
}
|
|
142
|
+
let babelrcPatterns = babelrcRoots;
|
|
143
|
+
if (!Array.isArray(babelrcPatterns)) {
|
|
144
|
+
babelrcPatterns = [babelrcPatterns];
|
|
145
|
+
}
|
|
146
|
+
babelrcPatterns = babelrcPatterns.map(pat => {
|
|
147
|
+
return typeof pat === "string" ? _path().resolve(babelrcRootsDirectory, pat) : pat;
|
|
148
|
+
});
|
|
149
|
+
if (babelrcPatterns.length === 1 && babelrcPatterns[0] === absoluteRoot) {
|
|
150
|
+
return pkgData.directories.includes(absoluteRoot);
|
|
151
|
+
}
|
|
152
|
+
return babelrcPatterns.some(pat => {
|
|
153
|
+
if (typeof pat === "string") {
|
|
154
|
+
pat = (0, _patternToRegex.default)(pat, babelrcRootsDirectory);
|
|
155
|
+
}
|
|
156
|
+
return pkgData.directories.some(directory => {
|
|
157
|
+
return matchPattern(pat, babelrcRootsDirectory, directory, context);
|
|
158
|
+
});
|
|
159
|
+
});
|
|
160
|
+
}
|
|
161
|
+
const validateConfigFile = (0, _caching.makeWeakCacheSync)(file => ({
|
|
162
|
+
filepath: file.filepath,
|
|
163
|
+
dirname: file.dirname,
|
|
164
|
+
options: (0, _options.validate)("configfile", file.options, file.filepath)
|
|
165
|
+
}));
|
|
166
|
+
const validateBabelrcFile = (0, _caching.makeWeakCacheSync)(file => ({
|
|
167
|
+
filepath: file.filepath,
|
|
168
|
+
dirname: file.dirname,
|
|
169
|
+
options: (0, _options.validate)("babelrcfile", file.options, file.filepath)
|
|
170
|
+
}));
|
|
171
|
+
const validateExtendFile = (0, _caching.makeWeakCacheSync)(file => ({
|
|
172
|
+
filepath: file.filepath,
|
|
173
|
+
dirname: file.dirname,
|
|
174
|
+
options: (0, _options.validate)("extendsfile", file.options, file.filepath)
|
|
175
|
+
}));
|
|
176
|
+
const loadProgrammaticChain = makeChainWalker({
|
|
177
|
+
root: input => buildRootDescriptors(input, "base", _configDescriptors.createCachedDescriptors),
|
|
178
|
+
env: (input, envName) => buildEnvDescriptors(input, "base", _configDescriptors.createCachedDescriptors, envName),
|
|
179
|
+
overrides: (input, index) => buildOverrideDescriptors(input, "base", _configDescriptors.createCachedDescriptors, index),
|
|
180
|
+
overridesEnv: (input, index, envName) => buildOverrideEnvDescriptors(input, "base", _configDescriptors.createCachedDescriptors, index, envName),
|
|
181
|
+
createLogger: (input, context, baseLogger) => buildProgrammaticLogger(input, context, baseLogger)
|
|
182
|
+
});
|
|
183
|
+
const loadFileChainWalker = makeChainWalker({
|
|
184
|
+
root: file => loadFileDescriptors(file),
|
|
185
|
+
env: (file, envName) => loadFileEnvDescriptors(file)(envName),
|
|
186
|
+
overrides: (file, index) => loadFileOverridesDescriptors(file)(index),
|
|
187
|
+
overridesEnv: (file, index, envName) => loadFileOverridesEnvDescriptors(file)(index)(envName),
|
|
188
|
+
createLogger: (file, context, baseLogger) => buildFileLogger(file.filepath, context, baseLogger)
|
|
189
|
+
});
|
|
190
|
+
function* loadFileChain(input, context, files, baseLogger) {
|
|
191
|
+
const chain = yield* loadFileChainWalker(input, context, files, baseLogger);
|
|
192
|
+
chain == null || chain.files.add(input.filepath);
|
|
193
|
+
return chain;
|
|
194
|
+
}
|
|
195
|
+
const loadFileDescriptors = (0, _caching.makeWeakCacheSync)(file => buildRootDescriptors(file, file.filepath, _configDescriptors.createUncachedDescriptors));
|
|
196
|
+
const loadFileEnvDescriptors = (0, _caching.makeWeakCacheSync)(file => (0, _caching.makeStrongCacheSync)(envName => buildEnvDescriptors(file, file.filepath, _configDescriptors.createUncachedDescriptors, envName)));
|
|
197
|
+
const loadFileOverridesDescriptors = (0, _caching.makeWeakCacheSync)(file => (0, _caching.makeStrongCacheSync)(index => buildOverrideDescriptors(file, file.filepath, _configDescriptors.createUncachedDescriptors, index)));
|
|
198
|
+
const loadFileOverridesEnvDescriptors = (0, _caching.makeWeakCacheSync)(file => (0, _caching.makeStrongCacheSync)(index => (0, _caching.makeStrongCacheSync)(envName => buildOverrideEnvDescriptors(file, file.filepath, _configDescriptors.createUncachedDescriptors, index, envName))));
|
|
199
|
+
function buildFileLogger(filepath, context, baseLogger) {
|
|
200
|
+
if (!baseLogger) {
|
|
201
|
+
return () => {};
|
|
202
|
+
}
|
|
203
|
+
return baseLogger.configure(context.showConfig, _printer.ChainFormatter.Config, {
|
|
204
|
+
filepath
|
|
205
|
+
});
|
|
206
|
+
}
|
|
207
|
+
function buildRootDescriptors({
|
|
208
|
+
dirname,
|
|
209
|
+
options
|
|
210
|
+
}, alias, descriptors) {
|
|
211
|
+
return descriptors(dirname, options, alias);
|
|
212
|
+
}
|
|
213
|
+
function buildProgrammaticLogger(_, context, baseLogger) {
|
|
214
|
+
var _context$caller;
|
|
215
|
+
if (!baseLogger) {
|
|
216
|
+
return () => {};
|
|
217
|
+
}
|
|
218
|
+
return baseLogger.configure(context.showConfig, _printer.ChainFormatter.Programmatic, {
|
|
219
|
+
callerName: (_context$caller = context.caller) == null ? void 0 : _context$caller.name
|
|
220
|
+
});
|
|
221
|
+
}
|
|
222
|
+
function buildEnvDescriptors({
|
|
223
|
+
dirname,
|
|
224
|
+
options
|
|
225
|
+
}, alias, descriptors, envName) {
|
|
226
|
+
var _options$env;
|
|
227
|
+
const opts = (_options$env = options.env) == null ? void 0 : _options$env[envName];
|
|
228
|
+
return opts ? descriptors(dirname, opts, `${alias}.env["${envName}"]`) : null;
|
|
229
|
+
}
|
|
230
|
+
function buildOverrideDescriptors({
|
|
231
|
+
dirname,
|
|
232
|
+
options
|
|
233
|
+
}, alias, descriptors, index) {
|
|
234
|
+
var _options$overrides;
|
|
235
|
+
const opts = (_options$overrides = options.overrides) == null ? void 0 : _options$overrides[index];
|
|
236
|
+
if (!opts) throw new Error("Assertion failure - missing override");
|
|
237
|
+
return descriptors(dirname, opts, `${alias}.overrides[${index}]`);
|
|
238
|
+
}
|
|
239
|
+
function buildOverrideEnvDescriptors({
|
|
240
|
+
dirname,
|
|
241
|
+
options
|
|
242
|
+
}, alias, descriptors, index, envName) {
|
|
243
|
+
var _options$overrides2, _override$env;
|
|
244
|
+
const override = (_options$overrides2 = options.overrides) == null ? void 0 : _options$overrides2[index];
|
|
245
|
+
if (!override) throw new Error("Assertion failure - missing override");
|
|
246
|
+
const opts = (_override$env = override.env) == null ? void 0 : _override$env[envName];
|
|
247
|
+
return opts ? descriptors(dirname, opts, `${alias}.overrides[${index}].env["${envName}"]`) : null;
|
|
248
|
+
}
|
|
249
|
+
function makeChainWalker({
|
|
250
|
+
root,
|
|
251
|
+
env,
|
|
252
|
+
overrides,
|
|
253
|
+
overridesEnv,
|
|
254
|
+
createLogger
|
|
255
|
+
}) {
|
|
256
|
+
return function* chainWalker(input, context, files = new Set(), baseLogger) {
|
|
257
|
+
const {
|
|
258
|
+
dirname
|
|
259
|
+
} = input;
|
|
260
|
+
const flattenedConfigs = [];
|
|
261
|
+
const rootOpts = root(input);
|
|
262
|
+
if (configIsApplicable(rootOpts, dirname, context, input.filepath)) {
|
|
263
|
+
flattenedConfigs.push({
|
|
264
|
+
config: rootOpts,
|
|
265
|
+
envName: undefined,
|
|
266
|
+
index: undefined
|
|
267
|
+
});
|
|
268
|
+
const envOpts = env(input, context.envName);
|
|
269
|
+
if (envOpts && configIsApplicable(envOpts, dirname, context, input.filepath)) {
|
|
270
|
+
flattenedConfigs.push({
|
|
271
|
+
config: envOpts,
|
|
272
|
+
envName: context.envName,
|
|
273
|
+
index: undefined
|
|
274
|
+
});
|
|
275
|
+
}
|
|
276
|
+
(rootOpts.options.overrides || []).forEach((_, index) => {
|
|
277
|
+
const overrideOps = overrides(input, index);
|
|
278
|
+
if (configIsApplicable(overrideOps, dirname, context, input.filepath)) {
|
|
279
|
+
flattenedConfigs.push({
|
|
280
|
+
config: overrideOps,
|
|
281
|
+
index,
|
|
282
|
+
envName: undefined
|
|
283
|
+
});
|
|
284
|
+
const overrideEnvOpts = overridesEnv(input, index, context.envName);
|
|
285
|
+
if (overrideEnvOpts && configIsApplicable(overrideEnvOpts, dirname, context, input.filepath)) {
|
|
286
|
+
flattenedConfigs.push({
|
|
287
|
+
config: overrideEnvOpts,
|
|
288
|
+
index,
|
|
289
|
+
envName: context.envName
|
|
290
|
+
});
|
|
291
|
+
}
|
|
292
|
+
}
|
|
293
|
+
});
|
|
294
|
+
}
|
|
295
|
+
if (flattenedConfigs.some(({
|
|
296
|
+
config: {
|
|
297
|
+
options: {
|
|
298
|
+
ignore,
|
|
299
|
+
only
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
}) => shouldIgnore(context, ignore, only, dirname))) {
|
|
303
|
+
return null;
|
|
304
|
+
}
|
|
305
|
+
const chain = emptyChain();
|
|
306
|
+
const logger = createLogger(input, context, baseLogger);
|
|
307
|
+
for (const {
|
|
308
|
+
config,
|
|
309
|
+
index,
|
|
310
|
+
envName
|
|
311
|
+
} of flattenedConfigs) {
|
|
312
|
+
if (!(yield* mergeExtendsChain(chain, config.options, dirname, context, files, baseLogger))) {
|
|
313
|
+
return null;
|
|
314
|
+
}
|
|
315
|
+
logger(config, index, envName);
|
|
316
|
+
yield* mergeChainOpts(chain, config);
|
|
317
|
+
}
|
|
318
|
+
return chain;
|
|
319
|
+
};
|
|
320
|
+
}
|
|
321
|
+
function* mergeExtendsChain(chain, opts, dirname, context, files, baseLogger) {
|
|
322
|
+
if (opts.extends === undefined) return true;
|
|
323
|
+
const file = yield* (0, _index.loadConfig)(opts.extends, dirname, context.envName, context.caller);
|
|
324
|
+
if (files.has(file)) {
|
|
325
|
+
throw new Error(`Configuration cycle detected loading ${file.filepath}.\n` + `File already loaded following the config chain:\n` + Array.from(files, file => ` - ${file.filepath}`).join("\n"));
|
|
326
|
+
}
|
|
327
|
+
files.add(file);
|
|
328
|
+
const fileChain = yield* loadFileChain(validateExtendFile(file), context, files, baseLogger);
|
|
329
|
+
files.delete(file);
|
|
330
|
+
if (!fileChain) return false;
|
|
331
|
+
mergeChain(chain, fileChain);
|
|
332
|
+
return true;
|
|
333
|
+
}
|
|
334
|
+
function mergeChain(target, source) {
|
|
335
|
+
target.options.push(...source.options);
|
|
336
|
+
target.plugins.push(...source.plugins);
|
|
337
|
+
target.presets.push(...source.presets);
|
|
338
|
+
for (const file of source.files) {
|
|
339
|
+
target.files.add(file);
|
|
340
|
+
}
|
|
341
|
+
return target;
|
|
342
|
+
}
|
|
343
|
+
function* mergeChainOpts(target, {
|
|
344
|
+
options,
|
|
345
|
+
plugins,
|
|
346
|
+
presets
|
|
347
|
+
}) {
|
|
348
|
+
target.options.push(options);
|
|
349
|
+
target.plugins.push(...(yield* plugins()));
|
|
350
|
+
target.presets.push(...(yield* presets()));
|
|
351
|
+
return target;
|
|
352
|
+
}
|
|
353
|
+
function emptyChain() {
|
|
354
|
+
return {
|
|
355
|
+
options: [],
|
|
356
|
+
presets: [],
|
|
357
|
+
plugins: [],
|
|
358
|
+
files: new Set()
|
|
359
|
+
};
|
|
360
|
+
}
|
|
361
|
+
function createConfigChainOptions(opts) {
|
|
362
|
+
const options = Object.assign({}, opts);
|
|
363
|
+
delete options.extends;
|
|
364
|
+
delete options.env;
|
|
365
|
+
delete options.overrides;
|
|
366
|
+
delete options.plugins;
|
|
367
|
+
delete options.presets;
|
|
368
|
+
delete options.passPerPreset;
|
|
369
|
+
delete options.ignore;
|
|
370
|
+
delete options.only;
|
|
371
|
+
delete options.test;
|
|
372
|
+
delete options.include;
|
|
373
|
+
delete options.exclude;
|
|
374
|
+
if (hasOwnProperty.call(options, "sourceMap")) {
|
|
375
|
+
options.sourceMaps = options.sourceMap;
|
|
376
|
+
delete options.sourceMap;
|
|
377
|
+
}
|
|
378
|
+
return options;
|
|
379
|
+
}
|
|
380
|
+
function dedupDescriptors(items) {
|
|
381
|
+
const map = new Map();
|
|
382
|
+
const descriptors = [];
|
|
383
|
+
for (const item of items) {
|
|
384
|
+
if (typeof item.value === "function") {
|
|
385
|
+
const fnKey = item.value;
|
|
386
|
+
let nameMap = map.get(fnKey);
|
|
387
|
+
if (!nameMap) {
|
|
388
|
+
nameMap = new Map();
|
|
389
|
+
map.set(fnKey, nameMap);
|
|
390
|
+
}
|
|
391
|
+
let desc = nameMap.get(item.name);
|
|
392
|
+
if (!desc) {
|
|
393
|
+
desc = {
|
|
394
|
+
value: item
|
|
395
|
+
};
|
|
396
|
+
descriptors.push(desc);
|
|
397
|
+
if (!item.ownPass) nameMap.set(item.name, desc);
|
|
398
|
+
} else {
|
|
399
|
+
desc.value = item;
|
|
400
|
+
}
|
|
401
|
+
} else {
|
|
402
|
+
descriptors.push({
|
|
403
|
+
value: item
|
|
404
|
+
});
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
return descriptors.reduce((acc, desc) => {
|
|
408
|
+
acc.push(desc.value);
|
|
409
|
+
return acc;
|
|
410
|
+
}, []);
|
|
411
|
+
}
|
|
412
|
+
function configIsApplicable({
|
|
413
|
+
options
|
|
414
|
+
}, dirname, context, configName) {
|
|
415
|
+
return (options.test === undefined || configFieldIsApplicable(context, options.test, dirname, configName)) && (options.include === undefined || configFieldIsApplicable(context, options.include, dirname, configName)) && (options.exclude === undefined || !configFieldIsApplicable(context, options.exclude, dirname, configName));
|
|
416
|
+
}
|
|
417
|
+
function configFieldIsApplicable(context, test, dirname, configName) {
|
|
418
|
+
const patterns = Array.isArray(test) ? test : [test];
|
|
419
|
+
return matchesPatterns(context, patterns, dirname, configName);
|
|
420
|
+
}
|
|
421
|
+
function ignoreListReplacer(_key, value) {
|
|
422
|
+
if (value instanceof RegExp) {
|
|
423
|
+
return String(value);
|
|
424
|
+
}
|
|
425
|
+
return value;
|
|
426
|
+
}
|
|
427
|
+
function shouldIgnore(context, ignore, only, dirname) {
|
|
428
|
+
if (ignore && matchesPatterns(context, ignore, dirname)) {
|
|
429
|
+
var _context$filename;
|
|
430
|
+
const message = `No config is applied to "${(_context$filename = context.filename) != null ? _context$filename : "(unknown)"}" because it matches one of \`ignore: ${JSON.stringify(ignore, ignoreListReplacer)}\` from "${dirname}"`;
|
|
431
|
+
debug(message);
|
|
432
|
+
if (context.showConfig) {
|
|
433
|
+
console.log(message);
|
|
434
|
+
}
|
|
435
|
+
return true;
|
|
436
|
+
}
|
|
437
|
+
if (only && !matchesPatterns(context, only, dirname)) {
|
|
438
|
+
var _context$filename2;
|
|
439
|
+
const message = `No config is applied to "${(_context$filename2 = context.filename) != null ? _context$filename2 : "(unknown)"}" because it fails to match one of \`only: ${JSON.stringify(only, ignoreListReplacer)}\` from "${dirname}"`;
|
|
440
|
+
debug(message);
|
|
441
|
+
if (context.showConfig) {
|
|
442
|
+
console.log(message);
|
|
443
|
+
}
|
|
444
|
+
return true;
|
|
445
|
+
}
|
|
446
|
+
return false;
|
|
447
|
+
}
|
|
448
|
+
function matchesPatterns(context, patterns, dirname, configName) {
|
|
449
|
+
return patterns.some(pattern => matchPattern(pattern, dirname, context.filename, context, configName));
|
|
450
|
+
}
|
|
451
|
+
function matchPattern(pattern, dirname, pathToTest, context, configName) {
|
|
452
|
+
if (typeof pattern === "function") {
|
|
453
|
+
return !!(0, _rewriteStackTrace.endHiddenCallStack)(pattern)(pathToTest, {
|
|
454
|
+
dirname,
|
|
455
|
+
envName: context.envName,
|
|
456
|
+
caller: context.caller
|
|
457
|
+
});
|
|
458
|
+
}
|
|
459
|
+
if (typeof pathToTest !== "string") {
|
|
460
|
+
throw new _configError.default(`Configuration contains string/RegExp pattern, but no filename was passed to Babel`, configName);
|
|
461
|
+
}
|
|
462
|
+
if (typeof pattern === "string") {
|
|
463
|
+
pattern = (0, _patternToRegex.default)(pattern, dirname);
|
|
464
|
+
}
|
|
465
|
+
return pattern.test(pathToTest);
|
|
466
|
+
}
|
|
467
|
+
0 && 0;
|
|
468
|
+
|
|
469
|
+
//# sourceMappingURL=config-chain.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_path","data","require","_debug","_options","_patternToRegex","_printer","_rewriteStackTrace","_configError","_index","_caching","_configDescriptors","debug","buildDebug","buildPresetChain","arg","context","chain","buildPresetChainWalker","plugins","dedupDescriptors","presets","options","map","o","createConfigChainOptions","files","Set","exports","makeChainWalker","root","preset","loadPresetDescriptors","env","envName","loadPresetEnvDescriptors","overrides","index","loadPresetOverridesDescriptors","overridesEnv","loadPresetOverridesEnvDescriptors","createLogger","makeWeakCacheSync","buildRootDescriptors","alias","createUncachedDescriptors","makeStrongCacheSync","buildEnvDescriptors","buildOverrideDescriptors","buildOverrideEnvDescriptors","buildRootChain","opts","configReport","babelRcReport","programmaticLogger","ConfigPrinter","programmaticChain","loadProgrammaticChain","dirname","cwd","undefined","programmaticReport","output","configFile","loadConfig","caller","findRootConfig","babelrc","babelrcRoots","babelrcRootsDirectory","configFileChain","emptyChain","configFileLogger","validatedFile","validateConfigFile","result","loadFileChain","mergeChain","ignoreFile","babelrcFile","isIgnored","fileChain","filename","pkgData","findPackageData","babelrcLoadEnabled","ignore","config","findRelativeConfig","add","filepath","shouldIgnore","validateBabelrcFile","babelrcLogger","showConfig","console","log","filter","x","join","fileHandling","absoluteRoot","directories","includes","babelrcPatterns","Array","isArray","pat","path","resolve","length","some","pathPatternToRegex","directory","matchPattern","file","validate","validateExtendFile","input","createCachedDescriptors","baseLogger","buildProgrammaticLogger","loadFileChainWalker","loadFileDescriptors","loadFileEnvDescriptors","loadFileOverridesDescriptors","loadFileOverridesEnvDescriptors","buildFileLogger","configure","ChainFormatter","Config","descriptors","_","_context$caller","Programmatic","callerName","name","_options$env","_options$overrides","Error","_options$overrides2","_override$env","override","chainWalker","flattenedConfigs","rootOpts","configIsApplicable","push","envOpts","forEach","overrideOps","overrideEnvOpts","only","logger","mergeExtendsChain","mergeChainOpts","extends","has","from","delete","target","source","Object","assign","passPerPreset","test","include","exclude","hasOwnProperty","call","sourceMaps","sourceMap","items","Map","item","value","fnKey","nameMap","get","set","desc","ownPass","reduce","acc","configName","configFieldIsApplicable","patterns","matchesPatterns","ignoreListReplacer","_key","RegExp","String","_context$filename","message","JSON","stringify","_context$filename2","pattern","pathToTest","endHiddenCallStack","ConfigError"],"sources":["../../src/config/config-chain.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-use-before-define */\n\nimport path from \"node:path\";\nimport buildDebug from \"debug\";\nimport type { Handler } from \"gensync\";\nimport { validate } from \"./validation/options.ts\";\nimport type {\n ConfigApplicableTest,\n BabelrcSearch,\n CallerMetadata,\n MatchItem,\n InputOptions,\n ConfigChainOptions,\n} from \"./validation/options.ts\";\nimport pathPatternToRegex from \"./pattern-to-regex.ts\";\nimport { ConfigPrinter, ChainFormatter } from \"./printer.ts\";\nimport type { ReadonlyDeepArray } from \"./helpers/deep-array.ts\";\n\nimport { endHiddenCallStack } from \"../errors/rewrite-stack-trace.ts\";\nimport ConfigError from \"../errors/config-error.ts\";\nimport type { PluginAPI, PresetAPI } from \"./helpers/config-api.ts\";\n\nconst debug = buildDebug(\"babel:config:config-chain\");\n\nimport {\n findPackageData,\n findRelativeConfig,\n findRootConfig,\n loadConfig,\n} from \"./files/index.ts\";\nimport type { ConfigFile, IgnoreFile, FilePackageData } from \"./files/index.ts\";\n\nimport { makeWeakCacheSync, makeStrongCacheSync } from \"./caching.ts\";\n\nimport {\n createCachedDescriptors,\n createUncachedDescriptors,\n} from \"./config-descriptors.ts\";\nimport type {\n UnloadedDescriptor,\n OptionsAndDescriptors,\n ValidatedFile,\n} from \"./config-descriptors.ts\";\n\nexport type ConfigChain = {\n plugins: UnloadedDescriptor<PluginAPI>[];\n presets: UnloadedDescriptor<PresetAPI>[];\n options: ConfigChainOptions[];\n files: Set<string>;\n};\n\nexport type PresetInstance = {\n options: InputOptions;\n alias: string;\n dirname: string;\n externalDependencies: ReadonlyDeepArray<string>;\n};\n\nexport type ConfigContext = {\n filename: string | undefined;\n cwd: string;\n root: string;\n envName: string;\n caller: CallerMetadata | undefined;\n showConfig: boolean;\n};\n\n/**\n * Build a config chain for a given preset.\n */\nexport function* buildPresetChain(\n arg: PresetInstance,\n context: any,\n): Handler<ConfigChain | null> {\n const chain = yield* buildPresetChainWalker(arg, context);\n if (!chain) return null;\n\n return {\n plugins: dedupDescriptors(chain.plugins),\n presets: dedupDescriptors(chain.presets),\n options: chain.options.map(o => createConfigChainOptions(o)),\n files: new Set(),\n };\n}\n\nexport const buildPresetChainWalker = makeChainWalker<PresetInstance>({\n root: preset => loadPresetDescriptors(preset),\n env: (preset, envName) => loadPresetEnvDescriptors(preset)(envName),\n overrides: (preset, index) => loadPresetOverridesDescriptors(preset)(index),\n overridesEnv: (preset, index, envName) =>\n loadPresetOverridesEnvDescriptors(preset)(index)(envName),\n createLogger: () => () => {}, // Currently we don't support logging how preset is expanded\n});\nconst loadPresetDescriptors = makeWeakCacheSync((preset: PresetInstance) =>\n buildRootDescriptors(preset, preset.alias, createUncachedDescriptors),\n);\nconst loadPresetEnvDescriptors = makeWeakCacheSync((preset: PresetInstance) =>\n makeStrongCacheSync((envName: string) =>\n buildEnvDescriptors(\n preset,\n preset.alias,\n createUncachedDescriptors,\n envName,\n ),\n ),\n);\nconst loadPresetOverridesDescriptors = makeWeakCacheSync(\n (preset: PresetInstance) =>\n makeStrongCacheSync((index: number) =>\n buildOverrideDescriptors(\n preset,\n preset.alias,\n createUncachedDescriptors,\n index,\n ),\n ),\n);\nconst loadPresetOverridesEnvDescriptors = makeWeakCacheSync(\n (preset: PresetInstance) =>\n makeStrongCacheSync((index: number) =>\n makeStrongCacheSync((envName: string) =>\n buildOverrideEnvDescriptors(\n preset,\n preset.alias,\n createUncachedDescriptors,\n index,\n envName,\n ),\n ),\n ),\n);\n\nexport type FileHandling = \"transpile\" | \"ignored\" | \"unsupported\";\nexport type RootConfigChain = ConfigChain & {\n babelrc: ConfigFile | undefined;\n config: ConfigFile | undefined;\n ignore: IgnoreFile | undefined;\n fileHandling: FileHandling;\n files: Set<string>;\n};\n\n/**\n * Build a config chain for Babel's full root configuration.\n */\nexport function* buildRootChain(\n opts: InputOptions,\n context: ConfigContext,\n): Handler<RootConfigChain | null> {\n let configReport, babelRcReport;\n const programmaticLogger = new ConfigPrinter();\n const programmaticChain = yield* loadProgrammaticChain(\n {\n options: opts,\n dirname: context.cwd,\n },\n context,\n undefined,\n programmaticLogger,\n );\n if (!programmaticChain) return null;\n const programmaticReport = yield* programmaticLogger.output();\n\n let configFile;\n if (typeof opts.configFile === \"string\") {\n configFile = yield* loadConfig(\n opts.configFile,\n context.cwd,\n context.envName,\n context.caller,\n );\n } else if (opts.configFile !== false) {\n configFile = yield* findRootConfig(\n context.root,\n context.envName,\n context.caller,\n );\n }\n\n let { babelrc, babelrcRoots } = opts;\n let babelrcRootsDirectory = context.cwd;\n\n const configFileChain = emptyChain();\n const configFileLogger = new ConfigPrinter();\n if (configFile) {\n const validatedFile = validateConfigFile(configFile);\n const result = yield* loadFileChain(\n validatedFile,\n context,\n undefined,\n configFileLogger,\n );\n if (!result) return null;\n configReport = yield* configFileLogger.output();\n\n // Allow config files to toggle `.babelrc` resolution on and off and\n // specify where the roots are.\n if (babelrc === undefined) {\n babelrc = validatedFile.options.babelrc;\n }\n if (babelrcRoots === undefined) {\n babelrcRootsDirectory = validatedFile.dirname;\n babelrcRoots = validatedFile.options.babelrcRoots;\n }\n\n mergeChain(configFileChain, result);\n }\n\n let ignoreFile, babelrcFile;\n let isIgnored = false;\n const fileChain = emptyChain();\n // resolve all .babelrc files\n if (\n (babelrc === true || babelrc === undefined) &&\n typeof context.filename === \"string\"\n ) {\n const pkgData = yield* findPackageData(context.filename);\n\n if (\n pkgData &&\n babelrcLoadEnabled(context, pkgData, babelrcRoots, babelrcRootsDirectory)\n ) {\n ({ ignore: ignoreFile, config: babelrcFile } = yield* findRelativeConfig(\n pkgData,\n context.envName,\n context.caller,\n ));\n\n if (ignoreFile) {\n fileChain.files.add(ignoreFile.filepath);\n }\n\n if (\n ignoreFile &&\n shouldIgnore(context, ignoreFile.ignore, null, ignoreFile.dirname)\n ) {\n isIgnored = true;\n }\n\n if (babelrcFile && !isIgnored) {\n const validatedFile = validateBabelrcFile(babelrcFile);\n const babelrcLogger = new ConfigPrinter();\n const result = yield* loadFileChain(\n validatedFile,\n context,\n undefined,\n babelrcLogger,\n );\n if (!result) {\n isIgnored = true;\n } else {\n babelRcReport = yield* babelrcLogger.output();\n mergeChain(fileChain, result);\n }\n }\n\n if (babelrcFile && isIgnored) {\n fileChain.files.add(babelrcFile.filepath);\n }\n }\n }\n\n if (context.showConfig) {\n console.log(\n `Babel configs on \"${context.filename}\" (ascending priority):\\n` +\n // print config by the order of ascending priority\n [configReport, babelRcReport, programmaticReport]\n .filter(x => !!x)\n .join(\"\\n\\n\") +\n \"\\n-----End Babel configs-----\",\n );\n }\n // Insert file chain in front so programmatic options have priority\n // over configuration file chain items.\n const chain = mergeChain(\n mergeChain(mergeChain(emptyChain(), configFileChain), fileChain),\n programmaticChain,\n );\n\n return {\n plugins: isIgnored ? [] : dedupDescriptors(chain.plugins),\n presets: isIgnored ? [] : dedupDescriptors(chain.presets),\n options: isIgnored\n ? []\n : chain.options.map(o => createConfigChainOptions(o)),\n fileHandling: isIgnored ? \"ignored\" : \"transpile\",\n ignore: ignoreFile || undefined,\n babelrc: babelrcFile || undefined,\n config: configFile || undefined,\n files: chain.files,\n };\n}\n\nfunction babelrcLoadEnabled(\n context: ConfigContext,\n pkgData: FilePackageData,\n babelrcRoots: BabelrcSearch | undefined,\n babelrcRootsDirectory: string,\n): boolean {\n if (typeof babelrcRoots === \"boolean\") return babelrcRoots;\n\n const absoluteRoot = context.root;\n\n // Fast path to avoid having to match patterns if the babelrc is just\n // loading in the standard root directory.\n if (babelrcRoots === undefined) {\n return pkgData.directories.includes(absoluteRoot);\n }\n\n let babelrcPatterns = babelrcRoots;\n if (!Array.isArray(babelrcPatterns)) {\n babelrcPatterns = [babelrcPatterns];\n }\n babelrcPatterns = babelrcPatterns.map(pat => {\n return typeof pat === \"string\"\n ? path.resolve(babelrcRootsDirectory, pat)\n : pat;\n });\n\n // Fast path to avoid having to match patterns if the babelrc is just\n // loading in the standard root directory.\n if (babelrcPatterns.length === 1 && babelrcPatterns[0] === absoluteRoot) {\n return pkgData.directories.includes(absoluteRoot);\n }\n\n return babelrcPatterns.some(pat => {\n if (typeof pat === \"string\") {\n pat = pathPatternToRegex(pat, babelrcRootsDirectory);\n }\n\n return pkgData.directories.some(directory => {\n return matchPattern(pat, babelrcRootsDirectory, directory, context);\n });\n });\n}\n\nconst validateConfigFile = makeWeakCacheSync(\n (file: ConfigFile): ValidatedFile => ({\n filepath: file.filepath,\n dirname: file.dirname,\n options: validate(\"configfile\", file.options, file.filepath),\n }),\n);\n\nconst validateBabelrcFile = makeWeakCacheSync(\n (file: ConfigFile): ValidatedFile => ({\n filepath: file.filepath,\n dirname: file.dirname,\n options: validate(\"babelrcfile\", file.options, file.filepath),\n }),\n);\n\nconst validateExtendFile = makeWeakCacheSync(\n (file: ConfigFile): ValidatedFile => ({\n filepath: file.filepath,\n dirname: file.dirname,\n options: validate(\"extendsfile\", file.options, file.filepath),\n }),\n);\n\n/**\n * Build a config chain for just the programmatic options passed into Babel.\n */\nconst loadProgrammaticChain = makeChainWalker({\n root: input => buildRootDescriptors(input, \"base\", createCachedDescriptors),\n env: (input, envName) =>\n buildEnvDescriptors(input, \"base\", createCachedDescriptors, envName),\n overrides: (input, index) =>\n buildOverrideDescriptors(input, \"base\", createCachedDescriptors, index),\n overridesEnv: (input, index, envName) =>\n buildOverrideEnvDescriptors(\n input,\n \"base\",\n createCachedDescriptors,\n index,\n envName,\n ),\n createLogger: (input, context, baseLogger) =>\n buildProgrammaticLogger(input, context, baseLogger),\n});\n\n/**\n * Build a config chain for a given file.\n */\nconst loadFileChainWalker = makeChainWalker<ValidatedFile>({\n root: file => loadFileDescriptors(file),\n env: (file, envName) => loadFileEnvDescriptors(file)(envName),\n overrides: (file, index) => loadFileOverridesDescriptors(file)(index),\n overridesEnv: (file, index, envName) =>\n loadFileOverridesEnvDescriptors(file)(index)(envName),\n createLogger: (file, context, baseLogger) =>\n buildFileLogger(file.filepath, context, baseLogger),\n});\n\nfunction* loadFileChain(\n input: ValidatedFile,\n context: ConfigContext,\n files: Set<ConfigFile>,\n baseLogger: ConfigPrinter,\n) {\n const chain = yield* loadFileChainWalker(input, context, files, baseLogger);\n chain?.files.add(input.filepath);\n\n return chain;\n}\n\nconst loadFileDescriptors = makeWeakCacheSync((file: ValidatedFile) =>\n buildRootDescriptors(file, file.filepath, createUncachedDescriptors),\n);\nconst loadFileEnvDescriptors = makeWeakCacheSync((file: ValidatedFile) =>\n makeStrongCacheSync((envName: string) =>\n buildEnvDescriptors(\n file,\n file.filepath,\n createUncachedDescriptors,\n envName,\n ),\n ),\n);\nconst loadFileOverridesDescriptors = makeWeakCacheSync((file: ValidatedFile) =>\n makeStrongCacheSync((index: number) =>\n buildOverrideDescriptors(\n file,\n file.filepath,\n createUncachedDescriptors,\n index,\n ),\n ),\n);\nconst loadFileOverridesEnvDescriptors = makeWeakCacheSync(\n (file: ValidatedFile) =>\n makeStrongCacheSync((index: number) =>\n makeStrongCacheSync((envName: string) =>\n buildOverrideEnvDescriptors(\n file,\n file.filepath,\n createUncachedDescriptors,\n index,\n envName,\n ),\n ),\n ),\n);\n\nfunction buildFileLogger(\n filepath: string,\n context: ConfigContext,\n baseLogger: ConfigPrinter | void,\n) {\n if (!baseLogger) {\n return () => {};\n }\n return baseLogger.configure(context.showConfig, ChainFormatter.Config, {\n filepath,\n });\n}\n\nfunction buildRootDescriptors(\n { dirname, options }: Partial<ValidatedFile>,\n alias: string,\n descriptors: (\n dirname: string,\n options: InputOptions,\n alias: string,\n ) => OptionsAndDescriptors,\n) {\n return descriptors(dirname, options, alias);\n}\n\nfunction buildProgrammaticLogger(\n _: unknown,\n context: ConfigContext,\n baseLogger: ConfigPrinter | void,\n) {\n if (!baseLogger) {\n return () => {};\n }\n return baseLogger.configure(context.showConfig, ChainFormatter.Programmatic, {\n callerName: context.caller?.name,\n });\n}\n\nfunction buildEnvDescriptors(\n { dirname, options }: Partial<ValidatedFile>,\n alias: string,\n descriptors: (\n dirname: string,\n options: InputOptions,\n alias: string,\n ) => OptionsAndDescriptors,\n envName: string,\n) {\n const opts = options.env?.[envName];\n return opts ? descriptors(dirname, opts, `${alias}.env[\"${envName}\"]`) : null;\n}\n\nfunction buildOverrideDescriptors(\n { dirname, options }: Partial<ValidatedFile>,\n alias: string,\n descriptors: (\n dirname: string,\n options: InputOptions,\n alias: string,\n ) => OptionsAndDescriptors,\n index: number,\n) {\n const opts = options.overrides?.[index];\n if (!opts) throw new Error(\"Assertion failure - missing override\");\n\n return descriptors(dirname, opts, `${alias}.overrides[${index}]`);\n}\n\nfunction buildOverrideEnvDescriptors(\n { dirname, options }: Partial<ValidatedFile>,\n alias: string,\n descriptors: (\n dirname: string,\n options: InputOptions,\n alias: string,\n ) => OptionsAndDescriptors,\n index: number,\n envName: string,\n) {\n const override = options.overrides?.[index];\n if (!override) throw new Error(\"Assertion failure - missing override\");\n\n const opts = override.env?.[envName];\n return opts\n ? descriptors(\n dirname,\n opts,\n `${alias}.overrides[${index}].env[\"${envName}\"]`,\n )\n : null;\n}\n\nfunction makeChainWalker<\n ArgT extends {\n options: InputOptions;\n dirname: string;\n filepath?: string;\n },\n>({\n root,\n env,\n overrides,\n overridesEnv,\n createLogger,\n}: {\n root: (configEntry: ArgT) => OptionsAndDescriptors;\n env: (configEntry: ArgT, env: string) => OptionsAndDescriptors | null;\n overrides: (configEntry: ArgT, index: number) => OptionsAndDescriptors;\n overridesEnv: (\n configEntry: ArgT,\n index: number,\n env: string,\n ) => OptionsAndDescriptors | null;\n createLogger: (\n configEntry: ArgT,\n context: ConfigContext,\n printer: ConfigPrinter | void,\n ) => (\n opts: OptionsAndDescriptors,\n index?: number | null,\n env?: string | null,\n ) => void;\n}): (\n configEntry: ArgT,\n context: ConfigContext,\n files?: Set<ConfigFile>,\n baseLogger?: ConfigPrinter,\n) => Handler<ConfigChain | null> {\n return function* chainWalker(input, context, files = new Set(), baseLogger) {\n const { dirname } = input;\n\n const flattenedConfigs: {\n config: OptionsAndDescriptors;\n index: number | undefined | null;\n envName: string | undefined | null;\n }[] = [];\n\n const rootOpts = root(input);\n if (configIsApplicable(rootOpts, dirname, context, input.filepath)) {\n flattenedConfigs.push({\n config: rootOpts,\n envName: undefined,\n index: undefined,\n });\n\n const envOpts = env(input, context.envName);\n if (\n envOpts &&\n configIsApplicable(envOpts, dirname, context, input.filepath)\n ) {\n flattenedConfigs.push({\n config: envOpts,\n envName: context.envName,\n index: undefined,\n });\n }\n\n (rootOpts.options.overrides || []).forEach((_, index) => {\n const overrideOps = overrides(input, index);\n if (configIsApplicable(overrideOps, dirname, context, input.filepath)) {\n flattenedConfigs.push({\n config: overrideOps,\n index,\n envName: undefined,\n });\n\n const overrideEnvOpts = overridesEnv(input, index, context.envName);\n if (\n overrideEnvOpts &&\n configIsApplicable(\n overrideEnvOpts,\n dirname,\n context,\n input.filepath,\n )\n ) {\n flattenedConfigs.push({\n config: overrideEnvOpts,\n index,\n envName: context.envName,\n });\n }\n }\n });\n }\n\n // Process 'ignore' and 'only' before 'extends' items are processed so\n // that we don't do extra work loading extended configs if a file is\n // ignored.\n if (\n flattenedConfigs.some(\n ({\n config: {\n options: { ignore, only },\n },\n }) => shouldIgnore(context, ignore, only, dirname),\n )\n ) {\n return null;\n }\n\n const chain = emptyChain();\n const logger = createLogger(input, context, baseLogger);\n\n for (const { config, index, envName } of flattenedConfigs) {\n if (\n !(yield* mergeExtendsChain(\n chain,\n config.options,\n dirname,\n context,\n files,\n baseLogger,\n ))\n ) {\n return null;\n }\n\n logger(config, index, envName);\n yield* mergeChainOpts(chain, config);\n }\n return chain;\n };\n}\n\nfunction* mergeExtendsChain(\n chain: ConfigChain,\n opts: InputOptions,\n dirname: string,\n context: ConfigContext,\n files: Set<ConfigFile>,\n baseLogger?: ConfigPrinter,\n): Handler<boolean> {\n if (opts.extends === undefined) return true;\n\n const file = yield* loadConfig(\n opts.extends,\n dirname,\n context.envName,\n context.caller,\n );\n\n if (files.has(file)) {\n throw new Error(\n `Configuration cycle detected loading ${file.filepath}.\\n` +\n `File already loaded following the config chain:\\n` +\n Array.from(files, file => ` - ${file.filepath}`).join(\"\\n\"),\n );\n }\n\n files.add(file);\n const fileChain = yield* loadFileChain(\n validateExtendFile(file),\n context,\n files,\n baseLogger,\n );\n files.delete(file);\n\n if (!fileChain) return false;\n\n mergeChain(chain, fileChain);\n\n return true;\n}\n\nfunction mergeChain(target: ConfigChain, source: ConfigChain): ConfigChain {\n target.options.push(...source.options);\n target.plugins.push(...source.plugins);\n target.presets.push(...source.presets);\n for (const file of source.files) {\n target.files.add(file);\n }\n\n return target;\n}\n\nfunction* mergeChainOpts(\n target: ConfigChain,\n { options, plugins, presets }: OptionsAndDescriptors,\n): Handler<ConfigChain> {\n target.options.push(options);\n target.plugins.push(...(yield* plugins()));\n target.presets.push(...(yield* presets()));\n\n return target;\n}\n\nfunction emptyChain(): ConfigChain {\n return {\n options: [],\n presets: [],\n plugins: [],\n files: new Set(),\n };\n}\n\nfunction createConfigChainOptions(opts: InputOptions): ConfigChainOptions {\n const options = {\n ...opts,\n };\n delete options.extends;\n delete options.env;\n delete options.overrides;\n delete options.plugins;\n delete options.presets;\n delete options.passPerPreset;\n delete options.ignore;\n delete options.only;\n delete options.test;\n delete options.include;\n delete options.exclude;\n\n // \"sourceMap\" is just aliased to sourceMap, so copy it over as\n // we merge the options together.\n if (Object.hasOwn(options, \"sourceMap\")) {\n options.sourceMaps = options.sourceMap;\n delete options.sourceMap;\n }\n return options;\n}\n\nfunction dedupDescriptors<API>(\n items: UnloadedDescriptor<API>[],\n): UnloadedDescriptor<API>[] {\n const map = new Map<\n Function,\n Map<string | void, { value: UnloadedDescriptor<API> }>\n >();\n\n const descriptors = [];\n\n for (const item of items) {\n if (typeof item.value === \"function\") {\n const fnKey = item.value;\n let nameMap = map.get(fnKey);\n if (!nameMap) {\n nameMap = new Map();\n map.set(fnKey, nameMap);\n }\n let desc = nameMap.get(item.name);\n if (!desc) {\n desc = { value: item };\n descriptors.push(desc);\n\n // Treat passPerPreset presets as unique, skipping them\n // in the merge processing steps.\n if (!item.ownPass) nameMap.set(item.name, desc);\n } else {\n desc.value = item;\n }\n } else {\n descriptors.push({ value: item });\n }\n }\n\n return descriptors.reduce((acc, desc) => {\n acc.push(desc.value);\n return acc;\n }, []);\n}\n\nfunction configIsApplicable(\n { options }: OptionsAndDescriptors,\n dirname: string,\n context: ConfigContext,\n configName: string,\n): boolean {\n return (\n (options.test === undefined ||\n configFieldIsApplicable(context, options.test, dirname, configName)) &&\n (options.include === undefined ||\n configFieldIsApplicable(context, options.include, dirname, configName)) &&\n (options.exclude === undefined ||\n !configFieldIsApplicable(context, options.exclude, dirname, configName))\n );\n}\n\nfunction configFieldIsApplicable(\n context: ConfigContext,\n test: ConfigApplicableTest,\n dirname: string,\n configName: string,\n): boolean {\n const patterns = Array.isArray(test) ? test : [test];\n\n return matchesPatterns(context, patterns, dirname, configName);\n}\n\n/**\n * Print the ignoreList-values in a more helpful way than the default.\n */\nfunction ignoreListReplacer(\n _key: string,\n value: MatchItem[] | MatchItem,\n): MatchItem[] | MatchItem | string {\n if (value instanceof RegExp) {\n return String(value);\n }\n\n return value;\n}\n\n/**\n * Tests if a filename should be ignored based on \"ignore\" and \"only\" options.\n */\nfunction shouldIgnore(\n context: ConfigContext,\n ignore: MatchItem[] | undefined | null,\n only: MatchItem[] | undefined | null,\n dirname: string,\n): boolean {\n if (ignore && matchesPatterns(context, ignore, dirname)) {\n const message = `No config is applied to \"${\n context.filename ?? \"(unknown)\"\n }\" because it matches one of \\`ignore: ${JSON.stringify(\n ignore,\n ignoreListReplacer,\n )}\\` from \"${dirname}\"`;\n debug(message);\n if (context.showConfig) {\n console.log(message);\n }\n return true;\n }\n\n if (only && !matchesPatterns(context, only, dirname)) {\n const message = `No config is applied to \"${\n context.filename ?? \"(unknown)\"\n }\" because it fails to match one of \\`only: ${JSON.stringify(\n only,\n ignoreListReplacer,\n )}\\` from \"${dirname}\"`;\n debug(message);\n if (context.showConfig) {\n console.log(message);\n }\n return true;\n }\n\n return false;\n}\n\n/**\n * Returns result of calling function with filename if pattern is a function.\n * Otherwise returns result of matching pattern Regex with filename.\n */\nfunction matchesPatterns(\n context: ConfigContext,\n patterns: MatchItem[],\n dirname: string,\n configName?: string,\n): boolean {\n return patterns.some(pattern =>\n matchPattern(pattern, dirname, context.filename, context, configName),\n );\n}\n\nfunction matchPattern(\n pattern: MatchItem,\n dirname: string,\n pathToTest: string | undefined,\n context: ConfigContext,\n configName?: string,\n): boolean {\n if (typeof pattern === \"function\") {\n return !!endHiddenCallStack(pattern)(pathToTest, {\n dirname,\n envName: context.envName,\n caller: context.caller,\n });\n }\n\n if (typeof pathToTest !== \"string\") {\n throw new ConfigError(\n `Configuration contains string/RegExp pattern, but no filename was passed to Babel`,\n configName,\n );\n }\n\n if (typeof pattern === \"string\") {\n pattern = pathPatternToRegex(pattern, dirname);\n }\n return pattern.test(pathToTest);\n}\n"],"mappings":";;;;;;;;AAEA,SAAAA,MAAA;EAAA,MAAAC,IA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