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

Unable to use TypeScript webpack config #7454

Closed
flippidippi opened this issue Oct 20, 2021 · 2 comments · Fixed by #7633
Closed

Unable to use TypeScript webpack config #7454

flippidippi opened this issue Oct 20, 2021 · 2 comments · Fixed by #7633
Assignees
Labels
outdated scope: node Issues related to Node, Express, NestJS support for Nx scope: react Issues related to React support for Nx type: bug

Comments

@flippidippi
Copy link

Current Behavior

When changing to use webpack.config.ts, it throws an error for syntax Unexpected token ':' (type declaration)

Expected Behavior

Users should be able to use TypeScript webpack configs and reference custom webpack plugins created in libs

Steps to Reproduce

Change to webpack.config.ts, add a type to something, change workspace.json on the @nrwl/node:build to point to TypeScript webpack config. Run serve on project.

https://github.com/flippidippi/nx-examples
Run npx nx run cart:serve.

Failure Logs

image

Environment

  Node : 16.6.2
  OS   : linux x64
  yarn : 1.22.17

  nx : 13.0.0-rc.1
  @nrwl/angular : 13.0.0-rc.1
  @nrwl/cli : 13.0.0-rc.1
  @nrwl/cypress : 13.0.0-rc.1
  @nrwl/devkit : 13.0.0-rc.1
  @nrwl/eslint-plugin-nx : 13.0.0-rc.1
  @nrwl/express : Not Found
  @nrwl/jest : 13.0.0-rc.1
  @nrwl/linter : 13.0.0-rc.1
  @nrwl/nest : Not Found
  @nrwl/next : Not Found
  @nrwl/node : Not Found
  @nrwl/nx-cloud : 12.5.0
  @nrwl/react : 13.0.0-rc.1
  @nrwl/schematics : Not Found
  @nrwl/tao : 13.0.0-rc.1
  @nrwl/web : 13.0.0-rc.1
  @nrwl/workspace : 13.0.0-rc.1
  @nrwl/storybook : 13.0.0-rc.1
  @nrwl/gatsby : Not Found
  typescript : 4.3.5
@FrozenPandaz FrozenPandaz added scope: node Issues related to Node, Express, NestJS support for Nx scope: react Issues related to React support for Nx labels Oct 22, 2021
@mandarini
Copy link
Member

Watching

ndcunningham added a commit to ndcunningham/nx that referenced this issue Nov 5, 2021
When a typescript webpack config file is provided as an option for the web build executor `nx run
project:serve` will not fail because the file type is typescript.

ISSUES CLOSED: nrwl#7454
ndcunningham added a commit to ndcunningham/nx that referenced this issue Nov 5, 2021
When a typescript webpack config file is provided as an option for the web build executor `nx
run
project:serve` will not fail because the file type is typescript.
ISSUES CLOSED: nrwl#7454
ndcunningham added a commit to ndcunningham/nx that referenced this issue Nov 5, 2021
…or react applications

When a typescript webpack config file is provided as an option for the web build executor `nx run
project:serve` will not fail because the file type is typescript.

ISSUES CLOSED: nrwl#7454
ndcunningham added a commit to ndcunningham/nx that referenced this issue Nov 5, 2021
…mpatible for react applications

When a typescript webpack config file is provided as an option for the web build executor `nx
run
project:serve` will not fail because the file type is typescript.
ISSUES CLOSED: nrwl#7454
ndcunningham added a commit to ndcunningham/nx that referenced this issue Nov 5, 2021
…are now compatible for react applications

When a typescript webpack config file is provided as an option for the web build executor
`nx
run
project:serve` will not fail because the file type is typescript.
ISSUES CLOSED: nrwl#7454
ndcunningham added a commit to ndcunningham/nx that referenced this issue Nov 5, 2021
…or react applications

When a typescript webpack config file is provided as an option for the web build executor
`nx
run
project:serve` will not fail because the file type is typescript.
ISSUES CLOSED: nrwl#7454
jaysoo pushed a commit that referenced this issue Nov 5, 2021
…or react applications (#7633)

When a typescript webpack config file is provided as an option for the web build executor
`nx
run
project:serve` will not fail because the file type is typescript.
ISSUES CLOSED: #7454
FrozenPandaz pushed a commit that referenced this issue Nov 11, 2021
…or react applications (#7633)

When a typescript webpack config file is provided as an option for the web build executor
`nx
run
project:serve` will not fail because the file type is typescript.
ISSUES CLOSED: #7454
@github-actions
Copy link

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated scope: node Issues related to Node, Express, NestJS support for Nx scope: react Issues related to React support for Nx type: bug
Projects
None yet
4 participants