Closed
Description
When writing externals for JS code, it is rather easy to unintentionally introduce extra code by not using the same external in the interface (.resi
) file. Therefore, whenever you are exposing an external, you need to make sure to copy the same external to your interface file to guarantee zero-cost bindings.
We previously had a note in the old docs that state
Note: do also use externals and the [@bs.blabla] attributes in the interface files. Otherwise the inlining won't happen.
This is an important note, so it should be added back to the External page.