3.0 source code
This commit is contained in:
23
OfficeWeb/vendor/requirejs/tests/bundles/bundles-tests.js
vendored
Normal file
23
OfficeWeb/vendor/requirejs/tests/bundles/bundles-tests.js
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
require({
|
||||
bundles: {
|
||||
'main': ['util', 'main'],
|
||||
'second': ['other'],
|
||||
'third': ['third']
|
||||
}
|
||||
}, ['util', 'other', 'third'], function (util, other, third) {
|
||||
|
||||
require(['main'], function (main) {
|
||||
doh.register(
|
||||
'bundles',
|
||||
[
|
||||
function bundles(t){
|
||||
t.is('util', util.name);
|
||||
t.is('other', other.name);
|
||||
t.is('third', third.name);
|
||||
t.is('main', main.name);
|
||||
}
|
||||
]
|
||||
);
|
||||
doh.run();
|
||||
});
|
||||
});
|
||||
16
OfficeWeb/vendor/requirejs/tests/bundles/bundles.html
vendored
Normal file
16
OfficeWeb/vendor/requirejs/tests/bundles/bundles.html
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>require.js: Bundles Config Test</title>
|
||||
<script type="text/javascript" src="../../require.js"></script>
|
||||
<script type="text/javascript" src="../doh/runner.js"></script>
|
||||
<script type="text/javascript" src="../doh/_browserRunner.js"></script>
|
||||
<script type="text/javascript" src="bundles-tests.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h1>require.js: Bundles Config Test</h1>
|
||||
<p>Test using the bundles config. More info:
|
||||
<a href="https://github.com/jrburke/requirejs/issues/497">497</a></p>
|
||||
<p>Check console for messages</p>
|
||||
</body>
|
||||
</html>
|
||||
8
OfficeWeb/vendor/requirejs/tests/bundles/main.js
vendored
Normal file
8
OfficeWeb/vendor/requirejs/tests/bundles/main.js
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
define('util', {
|
||||
name: 'util'
|
||||
});
|
||||
|
||||
define('main', {
|
||||
name: 'main'
|
||||
});
|
||||
|
||||
3
OfficeWeb/vendor/requirejs/tests/bundles/second.js
vendored
Normal file
3
OfficeWeb/vendor/requirejs/tests/bundles/second.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
define('other', {
|
||||
name: 'other'
|
||||
});
|
||||
3
OfficeWeb/vendor/requirejs/tests/bundles/third.js
vendored
Normal file
3
OfficeWeb/vendor/requirejs/tests/bundles/third.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
define('third', {
|
||||
name: 'third'
|
||||
});
|
||||
Reference in New Issue
Block a user