Code which has had it declaration will instantly getting paused in the event that debugger was discover
This disorder is only active in the event that transfer road try from an enthusiastic ESM transfer statement otherwise transfer() term. It can be used to add ESM-specific password.
This condition is active in the event the import path was off an excellent CommonJS wanted() telephone call. It can be utilized to add CommonJS-particular code.
This problem is active whenever esbuild’s system form is determined so you can web browser . It can be utilized to provide web browser-certain code.
This problem is effective when esbuild’s program means is decided in order to node . It can be utilized to provide node-certain code.
Note that when you use new want and you will transfer standards, their bundle might end up from the package several times! This might be a refined situation that cause bugs because of copy duplicates of code’s condition also bloating this new ensuing bundle. This will be popularly known as the new dual package chances. The primary technique for to stop this really is to put each of their password throughout the need reputation and have the import updates just be a white wrapper you to definitely phone calls wanted on your own bundle and re also-exports the box using ESM sentence structure.
This informs esbuild in order to revise your supply password ahead of strengthening so you’re able to lose specific constructs. Discover currently two you are able to things that might be decrease:
Passage so it banner factors most of the debugger statements becoming removed from the fresh productivity. This is exactly just like the lose_debugger: real flag in the favorite UglifyJS and Terser JavaScript minifiers.
JavaScript’s debugger statements result in the energetic debugger to relieve the fresh declaration since the an immediately-configured breakpoint. In the event that no debugger is actually unlock, this new report do absolutely nothing. Dropping such statements from your own password only suppress new debugger off immediately finishing if the code works.
- console
Passing so it flag factors all the console API calls getting got rid of throughout the output. This can be much like the get rid of_console: correct flag available in the popular UglifyJS and Terser JavaScript minifiers.
WARNING: With this banner can also be expose insects into your code! So it banner eliminates the whole label expression and additionally every label arguments. Or no ones arguments had extremely important side effects, with this particular flag may differ the latest choices of your own code. Feel careful when using which banner.
If you would like lose system API calls as opposed to deleting the latest objections having ill-effects (so you do not establish bugs), you need to ple, you could mark system.diary due to the fact sheer using –pure: system.record . wildbuddies hesap silme This can bring about these types of API phone calls to be eliminated safely whenever minification was permitted.
#Entryway names
That one control the fresh document labels of your returns records associated to each input entry point file. They configures the fresh new productivity routes playing with a layout with placeholders that could well be replaced with thinking certain into the file if the efficiency road is made. Like, specifying an entry name template of [dir]/ [name]- [hash] includes an effective hash of your output document regarding document term and you will sets the newest files to the yields list, potentially under a subdirectory (see the factual statements about [dir] below). Carrying out that looks in this way:
Here is the relative highway on the directory which has had the fresh new type in entry point document on the outbase list. The objective is always to help you stop collisions anywhere between identically-entitled admission things in different subdirectories.
Such, in the event the there have been two entryway situations src/ pages/ home/ list.ts and you may src/ pages/ about/ list.ts , the brand new outbase list is src , and admission names theme was [dir]/[name] , the latest returns directory tend to contain pages/ home/ list.js and you may users/ about/ directory.js . In the event the entryway brands template had been only [name] rather, bundling might have hit a brick wall since there would have been a few yields data with the exact same output road directory.js from inside the productivity list.