old-docs-site icon indicating copy to clipboard operation
old-docs-site copied to clipboard

It would be nice if the *-element repositories had an element.html for mass import

Open krainboltgreene opened this issue 9 years ago • 7 comments

Basically the title.

I realize I can create my own element.html that does dependency checking for me, but realistically for prototyping it'd be nice to just simply that whole process.

In addition (And I can make another issue for this) it'd also be nice to have an PolymerElement/elements repository, that depends on all elements.

krainboltgreene avatar Jul 28 '15 07:07 krainboltgreene

At one point we talked about including a 'meta' element that would import in everything inside a particular element collection but never ended up shipping it. I'm uncertain if there was a technical reason why or it just slipped through the cracks. @tjsavage may have some insight here.

addyosmani avatar Jul 28 '15 08:07 addyosmani

I have to say, I'm not even bothered that it did. This thing is so beautiful, not only in style, but also architecture and design.

Plus the whole elements chart thing? Genius.

Let me know if I can help get this piece in, otherwise yeah.

krainboltgreene avatar Jul 28 '15 09:07 krainboltgreene

cc @rictic as an FYI too

addyosmani avatar Aug 01 '15 13:08 addyosmani

In 0.5 land we provided something like this: https://github.com/Polymer/paper-elements/blob/master/paper-elements.html

It's useful for convenience. On the other hand, it's something of a performance footgun, which might be why we're not providing it anymore. Or maybe we just never got around to it in the post 0.8 world.

rictic avatar Aug 01 '15 16:08 rictic

Hmm, well is there a HTML import "compile" solution yet? Where I can automatically look at bower installs and build down to a elements.html of my own?

krainboltgreene avatar Aug 01 '15 17:08 krainboltgreene

The simple compilation solution is the vulcanize tool. If you're adventurous, we've just landed integration into closure compiler, which can enable significant further size wins.

Neither of these will be able to look into your bower dependencies to build out their imports, as there's not always a 1:1 mapping from bower packages to elements that you can import. A number of repos include more than one HTML file to import.

rictic avatar Aug 01 '15 17:08 rictic

Yeah, any concat tool would have to be knowledgable about <link rel="import" ...>. ~~Hmm. I mean it could be done.~~ I just looked at vulcanize, seems like it sovles my issue?

krainboltgreene avatar Aug 02 '15 03:08 krainboltgreene