codeswing icon indicating copy to clipboard operation
codeswing copied to clipboard

Adding a js file that is not script.js

Open ivanakcheurov opened this issue 2 years ago • 0 comments

I have created a basic HTML/CSS/JS codeswing. My index.html imports modelHandler.js. But codeswing only recongnizes script.js as a JS file but ignores modelHandler.js. How can I add modelHandler.js to the swing so that it is treated as part of the swing? (open the editor of this file when swing opens, refresh the preview on editing the file, etc.)

<script type="module">
    import { modelHandler } from "./src/modelHandler.js";
    window.modelHandler = new modelHandler();
</script>

ivanakcheurov avatar May 16 '23 11:05 ivanakcheurov