-
Notifications
You must be signed in to change notification settings - Fork 35
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
Remove roboto font from elements for faster page load #8
Comments
As @JosefJezek kindly pointed out, the font-roboto-local import is probably your best bet here. |
We're looking at removing |
It would be a good idea to do something similar with colors.html. The amount of colors is just too many imported by default. People that don't use the color theme (our site for example) at all will have to import those colors for nothing. Currently we're importing colors.html but don't use any of those colors in our own elements, instead we defined our own colors based on the color pattern. Maybe do something similar to how iron-icons does it, import one or two basic color schemes (e. g. google-blue and greyscale-shades) and the rest of it can be imported with colors-advanced-scheme.html or something like that. |
I am having the same issue. My app does not use Roboto, but Furthermore I'd argue that it is unacceptable for any user of this package to not be able to suppress cross-origin calls! E.g. what if I do not want my application to talk to Google's servers? |
+1 needs to be removed, for now i exclude it during vulcanization. |
You can simple resolve this issue using bower flat dependency tree. Check out this line... I am using empty I define fonts in index.html... |
@JosefJezek That's a workaround, not a resolution of the original issue. |
Also that workaround really kills time whenever you have to do a new build (guess you could automate it I guess but would be nicer to just have it removed). @notwaldorf I recall some talks about version 2.0 of all the elements in the future. Do you have a roadmap and outline what you want to achieve for the 2.0 milestone? Not just for this one but in general. It would be interesting to see where you are going (not just at the Polymer summit please, I really hate the pre-summit 3 months no updates at all wait time) and how we can help out potentially in the future. |
/cc @tjsavage |
@JosefJezek a much easier "workaround" would be to exclude it during vulcanization:
|
I'd be happy if the async attribute were added to the link[rel="stylesheet"] element that loads the font. |
Best solution for now:
this will clean the contents of Another option:
"ignoredDependencies": [
"font-roboto"
]
so {
...
{
"ignoredDependencies": [
"font-roboto"
]
}
...
}
Now you can run To build without errors run this command before build:
|
@TrueFusion for your specific case
|
@notwaldorf is |
@jaichandra The 2.0 elements didn't have any true breaking changes (that weren't required by the hybrid port), so |
so in the new year 2019 it still breaking the app and all element to jam in loading? |
I am currently working on a website and page speed is not sufficient. I'm currently looking at all the resources being loaded and trying to optimize. I've noticed I'm loading the roboto font which take a huge load of the loading time and I'm not even using roboto since I'm using my own fonts.
Is there an option to remove roboto from being loaded with paper elements without having to manually remove the roboto font in the individual paper-element font imports? This adds almost 4 seconds of loading time to my site and that's not even in production online.
The text was updated successfully, but these errors were encountered: