Skip to content

Commit a62c6cc

Browse files
committed
hello world
1 parent 8ce8e64 commit a62c6cc

File tree

6 files changed

+70
-0
lines changed

6 files changed

+70
-0
lines changed

examples/hello-world/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
2+
[Open fullscreen](https://html.activewidgets.com/hello-world/) | [Source on github](https://github.com/activewidgets/html/tree/master/examples/hello-world) | [Edit on Codesandbox](https://codesandbox.io/s/github/activewidgets/html/tree/master/examples/hello-world)
3+
4+
HTML (custom elements) example

examples/hello-world/index.html

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta charset="UTF-8" />
5+
<title>Hello World - ActiveWidgets/HTML</title>
6+
</head>
7+
<body>
8+
<ax-datagrid>Loading...</ax-datagrid>
9+
<script src="src/index.js"></script>
10+
</body>
11+
</html>

examples/hello-world/package.json

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"name": "html-hello-world",
3+
"version": "1.0.0",
4+
"description": "Hello World - ActiveWidgets/HTML",
5+
"keywords": [],
6+
"main": "src/index.js",
7+
"scripts": {
8+
"start": "parcel index.html --open",
9+
"build": "parcel build index.html"
10+
},
11+
"dependencies": {
12+
"@activewidgets/html": "0.0.10"
13+
},
14+
"devDependencies": {
15+
"parcel-bundler": "^1"
16+
},
17+
"private": true
18+
}

examples/hello-world/src/index.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
2+
import '@activewidgets/html';
3+
import './styles.css';
4+
5+
6+
let el = document.querySelector('ax-datagrid');
7+
8+
el.rows = [
9+
{ message: 'Hello, World!' }
10+
];
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
2+
body {
3+
margin: 60px;
4+
font: 14px/1.2143 'Segoe UI', 'Avenir', 'Helvetica Neue', 'Tahoma', sans-serif;
5+
}
6+
7+
.ax-datagrid {
8+
max-height: 80px;
9+
}
10+
11+
.ax-headers-view {
12+
font-weight: bold;
13+
color: #666;
14+
border-bottom: 1px solid #aaa;
15+
}
16+
17+
.ax-gridlines {
18+
border-bottom: 1px solid #eee;
19+
}

examples/viewer/examples.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
11

2+
import hello_world from '../hello-world/README.md';
3+
4+
5+
export const Local = {
6+
'Hello, World!': {path: 'hello-world', readme: hello_world}
7+
};
8+
9+
210
export * from '@activewidgets/datagrid/examples';
311

0 commit comments

Comments
 (0)