Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

fix build system #39

Merged
merged 1 commit into from
Aug 21, 2023
Merged

fix build system #39

merged 1 commit into from
Aug 21, 2023

Conversation

saade
Copy link
Member

@saade saade commented Aug 15, 2023

npm run dev

> dev
> npm-run-all --parallel dev:*


> dev:scripts
> node bin/build.js --dev


> dev:styles
> npx tailwindcss -i resources/css/index.css -o resources/dist/filament-tree.css --postcss --watch

Build started at 2:43:32 PM: ./resources/dist/filament-tree.js
Build finished at 2:43:32 PM: ./resources/dist/filament-tree.js
(node:56919) UnhandledPromiseRejectionWarning: ReferenceError: module is not defined in ES module scope
This file is being treated as an ES module because it has a '.js' file extension and '/Users/saade/GovDigital/govdigital/packages/filament-tree/package.json' contains "type": "module". To treat it as a CommonJS script, rename it to use the '.cjs' file extension.
    at file:///Users/saade/GovDigital/govdigital/packages/filament-tree/postcss.config.js:1:1
    at ModuleJob.run (internal/modules/esm/module_job.js:183:25)
    at async Loader.import (internal/modules/esm/loader.js:178:24)
    at async importDefault (/Users/saade/GovDigital/govdigital/packages/filament-tree/node_modules/postcss-load-config/src/index.js:71:18)
    at async Object.search (/Users/saade/GovDigital/govdigital/packages/filament-tree/node_modules/lilconfig/dist/index.js:130:37)
    at async loadPostCssPlugins (/Users/saade/GovDigital/govdigital/packages/filament-tree/node_modules/tailwindcss/lib/cli/build/plugin.js:60:12)
    at async createProcessor (/Users/saade/GovDigital/govdigital/packages/filament-tree/node_modules/tailwindcss/lib/cli/build/plugin.js:233:74)
    at async build (/Users/saade/GovDigital/govdigital/packages/filament-tree/node_modules/tailwindcss/lib/cli/build/index.js:39:21)
(Use `node --trace-warnings ...` to show where the warning was created)
(node:56919) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
(node:56919) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

and

npm run dev

> dev
> npm-run-all --parallel dev:*


> dev:styles
> npx tailwindcss -i resources/css/index.css -o resources/dist/filament-tree.css --postcss --watch


> dev:scripts
> node bin/build.js --dev

file:///Users/saade/GovDigital/govdigital/packages/filament-tree/postcss.config.js:1
module.exports = {
^

ReferenceError: module is not defined in ES module scope
This file is being treated as an ES module because it has a '.js' file extension and '/Users/saade/GovDigital/govdigital/packages/filament-tree/package.json' contains "type": "module". To treat it as a CommonJS script, rename it to use the '.cjs' file extension.
    at file:///Users/saade/GovDigital/govdigital/packages/filament-tree/postcss.config.js:1:1
    at ModuleJob.run (node:internal/modules/esm/module_job:194:25)

Node.js v18.17.1
ERROR: "dev:styles" exited with 1.

@awcodes awcodes merged commit 44870d1 into filamentphp:3.x Aug 21, 2023
1 check passed
@saade saade deleted the build branch August 22, 2023 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants