-
-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(All): move build to rollup, update core deps #175
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great to me!
@ZHollingshead Sorry Didn't state clearly WIP, I'm not sure if I should move wholesale to rollup, or one or few first and the rest later. |
@ZHollingshead @EisenbergEffect It would be also nice if we don't have to duplicate |
@bigopon Oh, whoops. Yeah I will get in and start testing. I would be okay with doing it all at once if it works. On the folder structure, originally you proposed an idea where we had the dist folder look like the following:
If we do that, then we can just put the folders in the root one time yeah? What is required for that to work though, is that a situation where we need to configure loaders specially? To be honest I am not sure how to update JSPM dependencies either. I am most experienced with Webpack at this point. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just doing this to clear my approval.
we have an options to set |
I'd love to see this converted all at once, if possible :) |
@EisenbergEffect @ZHollingshead That's pretty much it for the base work. Needs to update Webpack for html import in test, beside css test for all loaders to see if any issues. |
import { inject } from 'aurelia-dependency-injection'; | ||
import { StyleEngine, UxComponent, PaperRipple, normalizeBooleanAttribute } from '@aurelia-ux/core'; | ||
import { UxButtonTheme } from './ux-button-theme'; | ||
import UX_BUTTON_VIEW from './ux-button.html'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't we want the casing to be UxButtonView
instead of UX_BUTTON_VIEW
to be consistent?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was not sure about this, so I named it like a constant. Wouldn't be an issue if you want to proceed.
config.globalResources([ | ||
PLATFORM.moduleName('@aurelia-ux/button/ux-button') | ||
]); | ||
DOM.injectStyles(css, undefined, undefined, 'ux-button-css'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So I am not sure how I feel about the style injection happening in the index page. This feels like it would be a better fit in the components view-model, either in a custom decorator or just in the constructor.
The ideal scenario would have been figuring out why the require
tag is not working in Webpack when using rollup to move everything into a single file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can copy the .css
files over to dist to have it dynamically bundled. It will work fine, we just need to adjust the test to have those css
file properly mapped
close as no longer relevant, resolved by #229 |
Follow up the release of
[email protected]
&[email protected]
, we can register global resources with direct view model references. Now ux elements as a single bundle file, like following picThe entry
configure
will look like this:This can be applied for all elements, which should help reduce build time too.
@EisenbergEffect @ZHollingshead I not sure how to update jspm dependencies properly.
resolves #162
TODO list: