plugins icon indicating copy to clipboard operation
plugins copied to clipboard

typescript: Undocumented outputToFilesystem option emits warning if not present

Open danopia opened this issue 3 years ago • 1 comments

  • Rollup Plugin Name: @rollup/plugin-typescript
  • Rollup Plugin Version: 8.3.3

Documentation Is:

  • [x] Missing
  • [x] Needed
  • [ ] Confusing
  • [ ] Not Sure?

Please Explain in Detail...

When configured minimally (so, using defaults), the plugin is printing a warning:

(!) Plugin typescript: @rollup/plugin-typescript: outputToFilesystem option is defaulting to true.

This option is not documented on the README and the message doesn't have any further information. It's not clear what the options are to remove the warning.

Your Proposal for Changes

  1. The message could be more detailed: What did I do to introduce this warning? Is it related to a tsconfig.json option? Is there documentation it can link to, or a recommended action to take?
  2. The option should be added to the other options in the plugin documentation. When is it needed? What are the reasons to use either false or true here? Are there other possible values? Since what version has this flag been soft-required?

References

  • #1099

danopia avatar Jul 24 '22 08:07 danopia

Happy to review a PR with the changes you'd like to see.

shellscape avatar Aug 02 '22 16:08 shellscape

@shellscape the question is more : what needs to be done to remove the warning ?

mistic100 avatar Sep 26 '22 11:09 mistic100

I just ran into this today when trying to turn on incremental builds. When "incremental" is set to true in tsconfig this warning appears. At the same time a new ".rollup.cache" folder is created in project root. Could this warning be related to that?

vividlearningsystems avatar Oct 06 '22 20:10 vividlearningsystems

Hey folks. This issue hasn't received any traction for 60 days, so we're going to close this for housekeeping. If this is still an ongoing issue, please do consider contributing a Pull Request to resolve it. Further discussion is always welcome even with the issue closed. If anything actionable is posted in the comments, we'll consider reopening it.

stale[bot] avatar Dec 20 '22 22:12 stale[bot]

I think it should be reopened

ctretyak avatar Dec 21 '22 07:12 ctretyak

This ticket should be reopen and I believe it is related to Typescript Project References.

Bloodsucker avatar Jan 17 '23 09:01 Bloodsucker

➕ Can this be reopened? This is still a problem

ericmasiello avatar Mar 16 '23 18:03 ericmasiello

people, please read the bot message. it will be reopened when the community steps up to help.

shellscape avatar Mar 16 '23 18:03 shellscape

As a workaround, if you don't really need incremental compiling for TypeScript, just set incremental to false in your tsconfig.json. This did the trick for me. Thanks @vividlearningsystems for pointing that out.

vpalos avatar Mar 20 '23 10:03 vpalos

For reference, here is the IntelliSense for the property:

When set to false, force non-cached files to always be emitted in the output directory.output If not set, will default to true with a warning.

quisido avatar Sep 03 '23 01:09 quisido

Generally the behavior without this option set is technically correct despite the warning. The file outputted outside the bundle, the tsbuildinfo is not really part of the output, and as such, writing it using Rollup's emitFile doesn't matter and it can be written to the disk directly. But, this presents a warning to the user. On the other hand, enabling outputToFilesystem will write all output directly to the filesystem, bypassing Rollup, which is not desired. So maybe we just need an option to disable the warning, or otherwise not output it for files that are safe to write directly to the filesystem?

segevfiner avatar Oct 15 '23 23:10 segevfiner

Please reopen this issue. I really need incremental to be true for my project since it takes a really long time when building.

NotYoojun avatar Mar 11 '24 12:03 NotYoojun