Skip to content

Instantly share code, notes, and snippets.

@php-max
Created April 12, 2014 11:49
Show Gist options
  • Save php-max/10531880 to your computer and use it in GitHub Desktop.
Save php-max/10531880 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Hello Page</title>
</head>
<body>
<h1>Hi Hello Page</h1>
<script src="../../bower_components/requirejs/require.js"></script>
<script type="text/javascript" charset="utf-8">
require.config( {
baseUrl: "/",
packages: [ {
name: "lodash",
location: "bower_components/lodash-amd/"
}],
paths: {
"jquery": "bower_components/jquery/jquery",
"can": "bower_components/canjs/amd-dev/can",
"can/": "bower_components/canjs/amd-dev/can/",
"text":"bower_components/requirejs-text/text",
},
shim: {
"jquery": {
exports: "jQuery"
}
}
});
require(['lodash','./hello.js'], function(_) {
console.log(_);
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment