Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Consider removing TypeScript extensions when no preset supports them #1091

Closed
eliperelman opened this issue Sep 11, 2018 · 2 comments
Closed
Assignees
Milestone

Comments

@eliperelman
Copy link
Member

No description provided.

@edmorley
Copy link
Member

I think we should just remove them by default, since it gives the misleading impression that TypeScript is supported out of the box, and from what was said in #1044, their inclusion actually makes certain workflows more complicated.

Any third-party TypeScript preset could always then check neutrino.options.extensions and issue a warning if the user hasn't added added them in.

Long term it would be great if the middleware API allowed presets to declare which extensions they supported, and aggregated the list of extensions prior to the rest of the preset functionality being executed. (Since at the moment presets are only able to adjust extensions at the time they run, which is too late to adjust rules already configured eg lint)

@edmorley edmorley added this to the v9 milestone Sep 11, 2018
@edmorley
Copy link
Member

As a data point, manually removing .ts and .tsx from neutrino.config.resolve.extensions sped up compile times reported by webpack for Treeherder yarn start by ~330ms (2.5%). (Average of 4 runs with a warm cache)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

2 participants