Skip to content

Commit

Permalink
huge getting started documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
cblanquera committed Sep 4, 2024
1 parent 61dce35 commit bc6e1bf
Show file tree
Hide file tree
Showing 33 changed files with 7,144 additions and 57,525 deletions.
2,708 changes: 32 additions & 2,676 deletions docs/build/client/13781afd4fbd704a9789.js

Large diffs are not rendered by default.

2,757 changes: 33 additions & 2,724 deletions docs/build/client/1bf701a55aaad047771e.js

Large diffs are not rendered by default.

5,201 changes: 195 additions & 5,006 deletions docs/build/client/269f8b60f20cebb43be6.js

Large diffs are not rendered by default.

2,757 changes: 33 additions & 2,724 deletions docs/build/client/2d721d6aed73f41f4e72.js

Large diffs are not rendered by default.

2,757 changes: 33 additions & 2,724 deletions docs/build/client/3550a936d66e61695120.js

Large diffs are not rendered by default.

5,039 changes: 182 additions & 4,857 deletions docs/build/client/38ccffadc3c6e8b93d28.js

Large diffs are not rendered by default.

2,733 changes: 34 additions & 2,699 deletions docs/build/client/3e6a90cc5da3e950a902.js

Large diffs are not rendered by default.

2,811 changes: 36 additions & 2,775 deletions docs/build/client/57e37fa233b38c87fe71.js

Large diffs are not rendered by default.

2,860 changes: 37 additions & 2,823 deletions docs/build/client/75ff7698b5db04ad540c.js

Large diffs are not rendered by default.

2,860 changes: 37 additions & 2,823 deletions docs/build/client/8f2ff6d48aec3c3f0dc4.js

Large diffs are not rendered by default.

848 changes: 830 additions & 18 deletions docs/build/client/a67341498153885a2fc0.html

Large diffs are not rendered by default.

3,100 changes: 328 additions & 2,772 deletions docs/build/client/a67341498153885a2fc0.js

Large diffs are not rendered by default.

2,955 changes: 56 additions & 2,899 deletions docs/build/client/f01cefc94e8ee605f3f5.js

Large diffs are not rendered by default.

5,142 changes: 186 additions & 4,956 deletions docs/build/client/f859bf7a335e9eba03e0.js

Large diffs are not rendered by default.

1,037 changes: 123 additions & 914 deletions docs/build/server/13781afd4fbd704a9789.js

Large diffs are not rendered by default.

1,121 changes: 144 additions & 977 deletions docs/build/server/1bf701a55aaad047771e.js

Large diffs are not rendered by default.

1,887 changes: 267 additions & 1,620 deletions docs/build/server/269f8b60f20cebb43be6.js

Large diffs are not rendered by default.

1,121 changes: 145 additions & 976 deletions docs/build/server/2d721d6aed73f41f4e72.js

Large diffs are not rendered by default.

1,229 changes: 172 additions & 1,057 deletions docs/build/server/3550a936d66e61695120.js

Large diffs are not rendered by default.

971 changes: 108 additions & 863 deletions docs/build/server/38ccffadc3c6e8b93d28.js

Large diffs are not rendered by default.

1,015 changes: 120 additions & 895 deletions docs/build/server/3e6a90cc5da3e950a902.js

Large diffs are not rendered by default.

2,117 changes: 355 additions & 1,762 deletions docs/build/server/57e37fa233b38c87fe71.js

Large diffs are not rendered by default.

2,263 changes: 413 additions & 1,850 deletions docs/build/server/75ff7698b5db04ad540c.js

Large diffs are not rendered by default.

1,113 changes: 144 additions & 969 deletions docs/build/server/8f2ff6d48aec3c3f0dc4.js

Large diffs are not rendered by default.

2,080 changes: 995 additions & 1,085 deletions docs/build/server/a67341498153885a2fc0.js

Large diffs are not rendered by default.

1,399 changes: 214 additions & 1,185 deletions docs/build/server/f01cefc94e8ee605f3f5.js

Large diffs are not rendered by default.

949 changes: 103 additions & 846 deletions docs/build/server/f859bf7a335e9eba03e0.js

Large diffs are not rendered by default.

848 changes: 830 additions & 18 deletions docs/docs/getting-started.html

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions docs/styles/theme.css
Original file line number Diff line number Diff line change
Expand Up @@ -811,6 +811,7 @@ ide-app .body .panel-main {
background-color: #000000;
left: 150px;
top: 45px;
right: 0;
}

@media (max-width: 767px) {
Expand Down
6 changes: 1 addition & 5 deletions packages/temple-web/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,7 @@ type Next = () => void;
const docs = path.join(__dirname, '../../../docs');

//create temple compiler
const compiler = temple({
brand: '',
cwd: __dirname,
minify: false
});
const compiler = temple({ brand: '', cwd: __dirname });

//use temple ui
compiler.use(tui({ brand: '' }));
Expand Down
129 changes: 122 additions & 7 deletions packages/temple-web/src/modules/api/types.json
Original file line number Diff line number Diff line change
Expand Up @@ -1092,13 +1092,6 @@
"description": "The NodeJS EventEmitter instance being used.",
"example": "import emitter from 'events';\n\nconst compiler = temple({ emitter });'"
},
"type?": {
"kind": "property",
"list": false,
"type": ["document", "component", "template"],
"description": "Type of component",
"example": "const compiler = temple({ type: 'component' });'"
},
"minify?": {
"kind": "property",
"list": false,
Expand Down Expand Up @@ -1933,5 +1926,127 @@
"description": "Returns a signal object used to re-render components whenever its value changes",
"example": "const count = TempleAPI.signal(1, component)"
}
},
"Render Methods": {
"asset": {
"kind": "function",
"async": true,
"args": [
{
"kind": "property",
"list": false,
"name": "assetFile",
"type": "string"
}
],
"returns": {
"kind": "property",
"list": false,
"type": "Asset"
},
"description": "Returns a compiled build asset, given an asset file name.",
"example": "await compiler.asset('abc123.css'); //--> { type: 'text/css', content: '...' }"
},
"client": {
"kind": "function",
"async": true,
"args": [
{
"kind": "property",
"list": false,
"name": "sourceFile",
"type": "string"
}
],
"returns": {
"kind": "property",
"list": false,
"type": "string"
},
"description": "Returns a compiled client script, given the the template source file.",
"example": "await compiler.client('./docs/api.dtml'); //client script"
},
"markup": {
"kind": "function",
"async": true,
"args": [
{
"kind": "property",
"list": false,
"name": "sourceFile",
"type": "string"
}
],
"returns": {
"kind": "property",
"list": false,
"type": "string"
},
"description": "Returns a compiled markup, given the the template source file.",
"example": "await compiler.markup('./docs/api.dtml'); //--> <html>...</html>"
},
"render": {
"kind": "function",
"async": true,
"args": [
{
"kind": "property",
"list": false,
"name": "sourceFile",
"type": "string"
},
{
"kind": "property",
"list": false,
"name": "props",
"type": "Hash"
}
],
"returns": {
"kind": "property",
"list": false,
"type": "string"
},
"description": "Returns the final HTML markup, given the the template source file.",
"example": "await compiler.render('./docs/api.dtml', {\n title: 'API Documentation'\n});"
},
"server": {
"kind": "function",
"async": true,
"args": [
{
"kind": "property",
"list": false,
"name": "sourceFile",
"type": "string"
}
],
"returns": {
"kind": "property",
"list": false,
"type": "string"
},
"description": "Returns compiled server code, given the the template source file.",
"example": "await compiler.server('./docs/api.dtml'); // server script"
},
"styles": {
"kind": "function",
"async": true,
"args": [
{
"kind": "property",
"list": false,
"name": "sourceFile",
"type": "string"
}
],
"returns": {
"kind": "property",
"list": false,
"type": "string"
},
"description": "Returns compiled css styles, given the the template source file.",
"example": "await compiler.styles('./docs/api.dtml'); //css styles"
}
}
}
5 changes: 3 additions & 2 deletions packages/temple-web/src/modules/api/ui.tml
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,9 @@
<table class="tbl">
<thead>
<th>Property</th>
<th>Returns</th>
<if false={active.value.includes('Emitter')}>
<th>Returns</th>
</if>
<th>Description</th>
</thead>
<tbody>
Expand Down Expand Up @@ -217,7 +219,6 @@
</if>
<elif true={prop.kind === 'event'} />
<td valign="top" nowrap>{`on('${key}', (event: Event) => void)`}</td>
<td valign="top" nowrap>void</td>
</if>
<td>
<if true={prop.description}>
Expand Down
Loading

0 comments on commit bc6e1bf

Please sign in to comment.