-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.js
58 lines (51 loc) · 1.2 KB
/
main.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
var config = require.config({
paths: {
backbone: "assets/js/dependencies/backbone",
jquery: "assets/js/dependencies/jquery-2.1.1.min",
underscore: "assets/js/dependencies/underscore",
semantic: "assets/js/dependencies/semantic",
animatescroll: "assets/js/dependencies/animatescroll",
Index_View: "assets/js/index_package/index_view",
First_View: "assets/js/index_package/first_view",
router: "assets/js/router/router",
},
shim: {
backbone: {
deps: ['underscore', 'jquery'],
exports:'Backbone'
},
semantic: {
deps: ['jquery'],
},
animatescroll: {
deps: ['jquery'],
},
router: {
deps: ['backbone','jquery','Index_View','First_View'],
exports:'Router'
},
Index_View: {
deps: ['backbone', 'jquery', 'semantic','animatescroll'],
exports:'Index_View'
},
First_View: {
deps: ['backbone', 'jquery'],
exports:'First_View'
},
},
wrapShim: true,
suppress: { nodeShim: true }
});
require(['backbone',
'jquery',
'underscore',
'semantic',
'animatescroll',
'router',
'Index_View',
'First_View'],
function(Backbone,jquery, router,semantic){
console.log('main.js ready!');
new Router();
Backbone.history.start({});
})