You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ESbuild has a built-in text loader https://esbuild.github.io/content-types/#text, which allows us to load a file as a raw text string. So we are going to be able to load the HTML files as strings by making use of the text loader:
importcontentfrom'./xxx.html'
But it will throw an error that says ERROR: No loader is configured for ".html" files: xxx.html, I looked into the source code, it seems because the lack of the loader configs:
There is no way to specify the text loader, so how can we achieve that?
The text was updated successfully, but these errors were encountered:
ESbuild has a built-in text loader https://esbuild.github.io/content-types/#text, which allows us to load a file as a raw text string. So we are going to be able to load the HTML files as strings by making use of the text loader:
But it will throw an error that says
ERROR: No loader is configured for ".html" files: xxx.html
, I looked into the source code, it seems because the lack of the loader configs:There is no way to specify the text loader, so how can we achieve that?
The text was updated successfully, but these errors were encountered: