dbagchee/helix-preset-viewer

Split code into separate files

Closed this issue · 11 comments

Will make commits/merges easier - I'm trying to avoid needing a build script though. Need to do a little research on best way to break out the Vue stuff.

YES!

I think this should be a priority. I'll leave it up to you to determine the path forward.

Spent the last couple of hours researching this - tried webpack but had problems getting a basic project running...I may need to try again with fresh eyes tomorrow.

I just had a gander. Seems very involved...

It can't be this simple, can it be?
https://www.youtube.com/watch?v=rzel4E1JGsE

Ok following this I was able to launch a local Vue server:

https://cli.vuejs.org/guide/

I will need to refactor a bit of the code since some of the syntax is different while using Vue files but better to do it now than later - might take me a couple of days.

Will be following the Vue styleguide: https://vuejs.org/v2/style-guide/

I've been playing around more and getting further understanding of Vue. I've been trying to tackle the block order with split/join and alignment ideas. If we're going this option then I think we can implement the use of lodash and enable those array ordering.

Ok I've added the vue files - to work with these you'll need to install a couple npm packages as covered in https://cli.vuejs.org/guide/

What I haven't been able to figure out yet is how to default github pages to use the dist folder as the root folder for the app - so for the moment you can access the original all in one app at the default url and the Vue structured version at:

https://dbagchee.github.io/helix-preset-viewer/dist/index.html

Also I couldn't figure out how to include the hxModels and hxLabels files as external files so they are there but not being referenced at the moment so still need to figure that part out.

Ok figured out the hosting part - just run build, rename dist folder to docs and commit. The root index.html file is now retired. I'll close this and we can open new issues for any specific modularization.