Skip to content

Instantly share code, notes, and snippets.

@nashibao
Last active August 29, 2015 13:58
Show Gist options
  • Save nashibao/9975388 to your computer and use it in GitHub Desktop.
Save nashibao/9975388 to your computer and use it in GitHub Desktop.
Makefile to make `component/component` working with `requirejs`.

I found some modules of component/component (ex: lodash) may cause a problem with AMD module loader like requirejs.
You should delete locally the define property to make a component working nicely with these loaders.

like below..

install: components index.js
	component build --standalone app --out . --name app-temp
	sed -e "s/;(function(){/;(function(){var define = undefined;/g" app-temp.js > app.js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment