mirror of https://github.com/lukechilds/rollup.git
Rich-Harris
10 years ago
25 changed files with 161 additions and 31 deletions
@ -1,4 +1,3 @@ |
|||||
module.exports = { |
module.exports = { |
||||
description: 'block comments are printed correctly', |
description: 'block comments are printed correctly' |
||||
skip: true // work on this later
|
|
||||
}; |
}; |
||||
|
@ -0,0 +1,19 @@ |
|||||
|
define(function () { 'use strict'; |
||||
|
|
||||
|
/** |
||||
|
* Embiggens a number |
||||
|
* @param {number} num - the number to embiggen |
||||
|
* @param {number} factor - the factor to embiggen it by |
||||
|
* @returns {number} |
||||
|
*/ |
||||
|
function embiggen ( num, factor ) { |
||||
|
return num * factor; |
||||
|
} |
||||
|
|
||||
|
function foo () { |
||||
|
return embiggen( 6, 7 ); |
||||
|
} |
||||
|
|
||||
|
alert( foo() ); |
||||
|
|
||||
|
}); |
@ -0,0 +1,17 @@ |
|||||
|
'use strict'; |
||||
|
|
||||
|
/** |
||||
|
* Embiggens a number |
||||
|
* @param {number} num - the number to embiggen |
||||
|
* @param {number} factor - the factor to embiggen it by |
||||
|
* @returns {number} |
||||
|
*/ |
||||
|
function embiggen ( num, factor ) { |
||||
|
return num * factor; |
||||
|
} |
||||
|
|
||||
|
function foo () { |
||||
|
return embiggen( 6, 7 ); |
||||
|
} |
||||
|
|
||||
|
alert( foo() ); |
@ -0,0 +1,15 @@ |
|||||
|
/** |
||||
|
* Embiggens a number |
||||
|
* @param {number} num - the number to embiggen |
||||
|
* @param {number} factor - the factor to embiggen it by |
||||
|
* @returns {number} |
||||
|
*/ |
||||
|
function embiggen ( num, factor ) { |
||||
|
return num * factor; |
||||
|
} |
||||
|
|
||||
|
function foo () { |
||||
|
return embiggen( 6, 7 ); |
||||
|
} |
||||
|
|
||||
|
alert( foo() ); |
@ -0,0 +1,19 @@ |
|||||
|
(function () { 'use strict'; |
||||
|
|
||||
|
/** |
||||
|
* Embiggens a number |
||||
|
* @param {number} num - the number to embiggen |
||||
|
* @param {number} factor - the factor to embiggen it by |
||||
|
* @returns {number} |
||||
|
*/ |
||||
|
function embiggen ( num, factor ) { |
||||
|
return num * factor; |
||||
|
} |
||||
|
|
||||
|
function foo () { |
||||
|
return embiggen( 6, 7 ); |
||||
|
} |
||||
|
|
||||
|
alert( foo() ); |
||||
|
|
||||
|
})(); |
@ -0,0 +1,23 @@ |
|||||
|
(function (global, factory) { |
||||
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory() : |
||||
|
typeof define === 'function' && define.amd ? define(factory) : |
||||
|
factory(); |
||||
|
}(this, function () { 'use strict'; |
||||
|
|
||||
|
/** |
||||
|
* Embiggens a number |
||||
|
* @param {number} num - the number to embiggen |
||||
|
* @param {number} factor - the factor to embiggen it by |
||||
|
* @returns {number} |
||||
|
*/ |
||||
|
function embiggen ( num, factor ) { |
||||
|
return num * factor; |
||||
|
} |
||||
|
|
||||
|
function foo () { |
||||
|
return embiggen( 6, 7 ); |
||||
|
} |
||||
|
|
||||
|
alert( foo() ); |
||||
|
|
||||
|
})); |
@ -1 +1 @@ |
|||||
{"version":3,"file":"amd.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;AAAA,CAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHnC,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;ADFA,CAKA,GAAG,EAAE;AELL,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;AFFA,CAMA,GAAG,EAAE,;;"} |
{"version":3,"file":"amd.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;AAAA,CAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHnC,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;ADFA,CAKA,GAAG,EAAE;;AELL,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;AFFA,CAMA,GAAG,EAAE,;;"} |
||||
|
@ -1 +1 @@ |
|||||
{"version":3,"file":"cjs.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;AAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHpB,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;;ADGA,GAAG,EAAE;AELU,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;AFIA,GAAG,EAAE"} |
{"version":3,"file":"cjs.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;AAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHpB,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;;ADGA,GAAG,EAAE;;AELU,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;;AFIA,GAAG,EAAE"} |
||||
|
@ -1 +1 @@ |
|||||
{"version":3,"file":"es6.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":"AAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHpB,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;;ADGA,GAAG,EAAE;AELU,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;AFIA,GAAG,EAAE"} |
{"version":3,"file":"es6.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":"AAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHpB,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;;ADGA,GAAG,EAAE;;AELU,SAAS,GAAG,IAAI;AAC/B,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AACnC;;AFIA,GAAG,EAAE"} |
||||
|
@ -1 +1 @@ |
|||||
{"version":3,"file":"iife.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;AAAA,CAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHnC,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;ADFA,CAKA,GAAG,EAAE;AELL,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;AFFA,CAMA,GAAG,EAAE,;;"} |
{"version":3,"file":"iife.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;AAAA,CAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHnC,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;ADFA,CAKA,GAAG,EAAE;;AELL,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;AFFA,CAMA,GAAG,EAAE,;;"} |
||||
|
@ -1 +1 @@ |
|||||
{"version":3,"file":"umd.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;;;;;AAAA,CAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHnC,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;ADFA,CAKA,GAAG,EAAE;AELL,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;AFFA,CAMA,GAAG,EAAE,;;"} |
{"version":3,"file":"umd.js","sources":["../main.js","../foo.js","../bar.js"],"sourcesContent":["import foo from './foo';\nimport bar from './bar';\n\nconsole.log( 'hello from main.js' );\n\nfoo();\nbar();\n","export default function foo () {\n\tconsole.log( 'hello from foo.js' );\n}\n","export default function bar () {\n\tconsole.log( 'hello from bar.js' );\n}\n"],"names":[],"mappings":";;;;;;AAAA,CAGA,OAAO,CAAC,GAAG,EAAE,oBAAoB,EAAE;;ACHnC,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;ADFA,CAKA,GAAG,EAAE;;AELL,CAAe,SAAS,GAAG,IAAI;AAA/B,CACA,CAAC,OAAO,CAAC,GAAG,EAAE,mBAAmB,EAAE;AADnC,CAEA;;AFFA,CAMA,GAAG,EAAE,;;"} |
||||
|
Loading…
Reference in new issue