lasso-js / lasso

Advanced JavaScript module bundler, asset pipeline and optimizer
582 stars 75 forks source link

Extra files when bundle marko #259

Open Eldar-X opened 6 years ago

Eldar-X commented 6 years ago

I use lasso and marko for server side rendering and after i use lasso higher then v3.0.0.beta4 (Bundling Enabled) i have some extra output files with very very long names. For example

<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta http-equiv="X-UA-Compatible" content="ie=edge"><title>Updates</title></head><body><header id="admin-header">MY ADMIN HEADER</header>MY BODY <!--M#s0-2--><div>test</div><!--M/s0-2--><script src="/admin/updates.js"></script>
<script src="/admin/Users-eldar-x-Projeler-NodeJs-elix-commerce-content-admin-components-test-index.marko.register.js"></script>
<script src="/admin/Users-eldar-x-Projeler-NodeJs-elix-commerce-content-admin-default-pages-dashboard-updates-template.marko.init.js"></script>
<script>$_mod.ready();</script><script src="http://localhost:57590/browser-refresh.js"></script><script>(function(){var w=window;w.$components=(w.$components||[]).concat({"w":[["s0-2",0,{},{"f":1}]],"t":["/elix-commerce$1.0.0/content/admin/components/test/index.marko"]})||w.$components})()</script></body></html>

as you can see there are some files like "/admin/Users-eldar-x-Projeler-NodeJs-elix-commerce-content-admin-default-pages-dashboard-updates-template.marko.init.js"

also i must notice that in prev version of lasso if in my template file there isn't any client side components lasso didn't create js files but now it's create them.

Sorry for my broken English

My system info: os: Macos 10.13.2 (17C88) node: 9.3.0 lasso: 3.1.0 lasso/marko-taglib: 1.0.8 lasso-marko: 2.4.0 marko: 4.7.4

ianvonholt commented 6 years ago

I'm seeing this as well, even with bundling turned on in the v3 branch.

Is there any particular reason that init scripts are not in the page bundle with v3?

@austinkelleher