This project is depricated. Only for meteor < 1.3 #For meteor 1.3+ we have Synthesis
Automates Polymer vulcanizing in Meteor
Actually its difficult to code Polymer with Meteor, Meteor not support extra <template> tag, You can solve it by 2 ways
- Keep all
bower_components,custom polymer elements, etc in public folder, Manually vulcanize, Deletebower_componentsafter vulcanizing (bower_compuments increases app size) - Keep html inside javascript (like .jsx in react)
mwc:compiler automatically watch Polymer project folder anywhere in local file system & added to meteor after vulcanizing
Install mwc:compiler package to your Meteor App
$ meteor add mwc:compilerKeep the compiler.mwc.json named configuration file with the following properties under /client folder of your Meteor App.
root[String] : Root directory from whichhtml,js,css,etc files to be compiled and vulcanized. Root directory should be a .(dot) folder to avoid meteor watching the files. Compiler has a dedicated watcher to do that. eg .polymer.append[Array] : Files specified here will be appended toweb.bowser,web.cordovabuilds after vulcanizing.import[Array] : Files to be vulcanised topublic/mwc_compiler.html& imported to<head>.
Here is a sample compiler.mwc.json:
{
"root" : ".polymer",
"append": [
"index.html",
"my_class.html"
],
"import": [
"bower_components/font-roboto/roboto.html",
"bower_components/paper-header-panel/paper-header-panel.html",
"bower_components/paper-scroll-header-panel/paper-scroll-header-panel.html",
"bower_components/polymer/polymer.html",
"linto/card-route.html"
],
"extensions": {
"mwc:[email protected]": {
"compileFunction": "MWCEcmascript"
}
}
}
Refer https://github.com/meteorwebcomponents/extensions for more details on extensions.
Keep all bower_components, custom polymer elements, etc in the root (here it will be .polymer) vulcanizer root directory.
##Related Projects
MWC Mixin - Mixin for polymer/webcomponents in meteor.
MWC Router - Reactive routing for polymer/webcomponents in meteor.
MWC Layout - polymer layout renderer
- Basic Example with flowrouter - mwc-flowrouter
- Apps Using
mwc:compiler- Free Ebooks, TorrentAlert

