Skip to content

Commit 4424e87

Browse files
committed
test: bundling
1 parent 9eb3900 commit 4424e87

File tree

11 files changed

+10666
-0
lines changed

11 files changed

+10666
-0
lines changed

test/bundling/rollup/package-lock.json

Lines changed: 472 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/bundling/rollup/package.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"name": "rollup",
3+
"version": "1.0.0",
4+
"description": "",
5+
"main": "index.js",
6+
"scripts": {
7+
"build": "rollup -c rollup.config.mjs"
8+
},
9+
"dependencies": {
10+
"bson": "../../.."
11+
},
12+
"private": true,
13+
"devDependencies": {
14+
"@rollup/plugin-node-resolve": "^15.0.1",
15+
"rollup": "^3.5.1"
16+
}
17+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
'use strict';
2+
3+
import { nodeResolve } from '@rollup/plugin-node-resolve';
4+
5+
export default {
6+
input: 'src/index.js',
7+
output: {
8+
file: 'dist/index.mjs',
9+
format: 'esm',
10+
sourcemap: true
11+
},
12+
plugins: [nodeResolve()]
13+
};

test/bundling/rollup/src/index.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
'use strict';
2+
3+
import * as BSON from 'bson';
4+
5+
console.log(BSON.serialize);

test/bundling/webpack/README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# 🚀 Welcome to your new awesome project!
2+
3+
This project has been created using **webpack-cli**, you can now run
4+
5+
```
6+
npm run build
7+
```
8+
9+
or
10+
11+
```
12+
yarn build
13+
```
14+
15+
to bundle your application

test/bundling/webpack/index.html

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta charset="utf-8" />
5+
<title>Webpack App</title>
6+
<script src="./dist/index.js"></script>
7+
</head>
8+
<body>
9+
<h1>Hello world!</h1>
10+
<h2>Tip: Check your console</h2>
11+
</body>
12+
</html>

0 commit comments

Comments
 (0)