Skip to content

Commit

Permalink
small docs edit
Browse files Browse the repository at this point in the history
  • Loading branch information
ingewortel committed May 1, 2020
1 parent b82fc81 commit 4ee748e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -13983,7 +13983,7 @@
"kind": "manual",
"longname": "/Users/ingewortel/Documents/projects/Github/artistoo/manual/htmlTemplate.md",
"name": "./manual/htmlTemplate.md",
"content": "# An HTML template page\n\nThis tutorial will take you through the HTML simulation template \nstep by step so you know which parts you may have to adapt when \nyou are building your own simulations.\n\n### An HTML template\n\nWe will build the following template:\n\n```$xslt\n<!-- Page setup and title -->\n<!DOCTYPE html>\n<html lang=\"en\">\n<head><meta http-equiv=\"Content-Type\" content=\"text/html;\ncharset=UTF-8\">\n<title>PageTitle</title>\n<style type=\"text/css\"> \nbody{\n font-family: \"HelveticaNeue-Light\", sans-serif; padding : 15px;\n}\n</style>\n\n<!-- Sourcing the cpm build -->\n<script src=\"../../build/artistoo.js\"></script>\n<script>\n\"use strict\"\n\n // Simulation code here.\n\n\n</script>\n</head>\n<body onload=\"initialize()\">\n<h1>Your Page Title</h1>\n<p>\nDescription of your page.\n</p>\n</body>\n</html>\n```\n\nWe will now go through this step by step.\n\n### Step 1 : Create a basic HTML page\n\nA very simple html page looks like this:\n\n```$xslt\n<!DOCTYPE html>\n<html>\n<head> </head>\n<body> </body>\n</html>\n```\n\nThe `<html>` tag shows where the page starts, and `</html>` shows where it ends.\nThe page consists of a *header*, which starts at `<head>` and ends at `</head>`,\nand a *body*, starting at `<body>` and ending at `</body>`. (In general,\nanything you place in your HTML file starts with `<something>` and ends with\n`</something>`).\n\n### Step 2 : Configure the header\n\nThe header of the HTML page is the place that contains some meta-information\nabout that page, and will also contain the simulation code.\n\nFirst, we will expand the header code above (between the `<head></head>` tags):\n\n```$xslt\n<head><meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\n<title>PageTitle</title>\n</head>\n```\n\nThe additional code in the first line just includes some document settings into \nthe header that you will rarely need to change. The only thing you may want to \nchange is the second line, where you set the title that will be displayed\nin the open tab in your web browser when you open the page.\n\n### Step 3 : Add JavaScript\n\nWe will now add some JavaScript code to the header part of the page (again,\nbetween the `<head></head>` tags):\n\n```$xslt\n<head><meta http-equiv=\"Content-Type\" content=\"text/html;charset=UTF-8\">\n<title>PageTitle</title>\n<script src=\"path/to/artistoo/build/artistoo.js\"></script>\n<script>\n\"use strict\"\n// Simulation code will go here:\n\n</script>\n</head>\n```\n\nThe first script just loads the Artistoo package for HTML, which is stored in\n`artistoo/build/artistoo.js`. Please ensure that the path supplied here is the correct\npath from the folder where you stored `MyFirstSimulation.html` to the file\n`artistoo/build/artistoo.js`. If you have stored your simulation in `artistoo/examples/html`,\nyou can use the path `../../build/artistoo.js`\n\n\nThe second script is where your actual simulation code\nwill go when you are [Writing your simulation](quickstart.html#writing-your-simulation).\nFor now, we'll leave it empty.\n\n### Step 4: Write the body\n\nFinally, we make some changes to the body of the page (between the `<body></body>` tags):\n\n```$xslt\n<body onload=\"initialize()\">\n<h1>Your Page Title</h1>\n<p>\nDescription of your page.\n</p>\n</body>\n```\n\nIn the first line, we tell the HTML page to run the JavaScript function \n`intitialize()`, which we will define later in \n[Writing your simulation](quickstart.html#writing-your-simulation) (between the \n`<script></script>` tags of the page header we just set up).\n\nThe rest of the code just adds a title and a description to the web page.\nThe simulation will then be placed below (as in the example shown\nat the top of this page).\n\n### Step 5 (optional): Add CSS\n\nThe code we have now added is sufficient to make the page work once we have\n[added a simulation](quickstart.html#writing-your-simulation), but to make it look better we\nmay want to add some CSS styling code to the header of the page. The header now\nbecomes:\n\n```$xslt\n\n<head><meta http-equiv=\"Content-Type\" content=\"text/html;charset=UTF-8\">\n<title>PageTitle</title>\n\n<style type=\"text/css\"> \nbody{\nfont-family: \"HelveticaNeue-Light\", sans-serif; padding : 15px;\n}\n</style>\n\n<script src=\"path/to/artistoo/build/artistoo.js\"></script>\n<script>\n\"use strict\"\n// Simulation code will go here:\n\n</script>\n</head>\n```\n\nTo see the final result, have a look again at the complete\n [template](#an-html-template). You can now proceed with\n [adding your simulation](quickstart.html#writing-your-simulation) to this file.",
"content": "# An HTML template page\n\nThis tutorial will take you through the HTML simulation template \nstep by step so you know which parts you may have to adapt when \nyou are building your own simulations.\n\n### An HTML template\n\nWe will build the following template:\n\n```$xslt\n<!-- Page setup and title -->\n<!DOCTYPE html>\n<html lang=\"en\">\n<head><meta http-equiv=\"Content-Type\" content=\"text/html;\ncharset=UTF-8\">\n<title>PageTitle</title>\n<style type=\"text/css\"> \nbody{\n font-family: \"HelveticaNeue-Light\", sans-serif; padding : 15px;\n}\n</style>\n\n<!-- Sourcing the cpm build -->\n<script src=\"../../build/artistoo.js\"></script>\n<script>\n\"use strict\"\n\n // Simulation code here.\n\n\n</script>\n</head>\n<body onload=\"initialize()\">\n<h1>Your Page Title</h1>\n<p>\nDescription of your page.\n</p>\n</body>\n</html>\n```\n\nWe will now go through this step by step.\n\n### Step 1 : Create a basic HTML page\n\nA very simple HTML page looks like this:\n\n```$xslt\n<!DOCTYPE html>\n<html>\n<head> </head>\n<body> </body>\n</html>\n```\n\nThe `<html>` tag shows where the page starts, and `</html>` shows where it ends.\nThe page consists of a *header*, which starts at `<head>` and ends at `</head>`,\nand a *body*, starting at `<body>` and ending at `</body>`. (In general,\nanything you place in your HTML file starts with `<something>` and ends with\n`</something>`).\n\n### Step 2 : Configure the header\n\nThe header of the HTML page is the place that contains some meta-information\nabout that page, and will also contain the simulation code.\n\nFirst, we will expand the header code above (between the `<head></head>` tags):\n\n```$xslt\n<head><meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\n<title>PageTitle</title>\n</head>\n```\n\nThe additional code in the first line just includes some document settings into \nthe header that you will rarely need to change. The only thing you may want to \nchange is the second line, where you set the title that will be displayed\nin the open tab in your web browser when you open the page.\n\n### Step 3 : Add JavaScript\n\nWe will now add some JavaScript code to the header part of the page (again,\nbetween the `<head></head>` tags):\n\n```$xslt\n<head><meta http-equiv=\"Content-Type\" content=\"text/html;charset=UTF-8\">\n<title>PageTitle</title>\n<script src=\"path/to/artistoo/build/artistoo.js\"></script>\n<script>\n\"use strict\"\n// Simulation code will go here:\n\n</script>\n</head>\n```\n\nThe first script just loads the Artistoo package for HTML, which is stored in\n`artistoo/build/artistoo.js`. Please ensure that the path supplied here is the correct\npath from the folder where you stored `MyFirstSimulation.html` to the file\n`artistoo/build/artistoo.js`. If you have stored your simulation in `artistoo/examples/html`,\nyou can use the path `../../build/artistoo.js`\n\n\nThe second script is where your actual simulation code\nwill go when you are [Writing your simulation](quickstart.html#writing-your-simulation).\nFor now, we'll leave it empty.\n\n### Step 4: Write the body\n\nFinally, we make some changes to the body of the page (between the `<body></body>` tags):\n\n```$xslt\n<body onload=\"initialize()\">\n<h1>Your Page Title</h1>\n<p>\nDescription of your page.\n</p>\n</body>\n```\n\nIn the first line, we tell the HTML page to run the JavaScript function \n`intitialize()`, which we will define later in \n[Writing your simulation](quickstart.html#writing-your-simulation) (between the \n`<script></script>` tags of the page header we just set up).\n\nThe rest of the code just adds a title and a description to the web page.\nThe simulation will then be placed below (as in the example shown\nat the top of this page).\n\n### Step 5 (optional): Add CSS\n\nThe code we have now added is sufficient to make the page work once we have\n[added a simulation](quickstart.html#writing-your-simulation), but to make it look better we\nmay want to add some CSS styling code to the header of the page. The header now\nbecomes:\n\n```$xslt\n\n<head><meta http-equiv=\"Content-Type\" content=\"text/html;charset=UTF-8\">\n<title>PageTitle</title>\n\n<style type=\"text/css\"> \nbody{\nfont-family: \"HelveticaNeue-Light\", sans-serif; padding : 15px;\n}\n</style>\n\n<script src=\"path/to/artistoo/build/artistoo.js\"></script>\n<script>\n\"use strict\"\n// Simulation code will go here:\n\n</script>\n</head>\n```\n\nTo see the final result, have a look again at the complete\n [template](#an-html-template). You can now proceed with\n [adding your simulation](quickstart.html#writing-your-simulation) to this file.",
"static": true,
"access": "public"
},
Expand Down
2 changes: 1 addition & 1 deletion docs/manual/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@ <h3 id="but-what-about-speed-">But what about speed?</h3>
&lt;/html&gt;</code>
</code></pre>
<p>We will now go through this step by step.
</p><h3>Step 1 : Create a basic HTML page</h3><p>A very simple html page looks like this:</p><pre><code class="lang-$xslt"><code class="source-code prettyprint">&lt;!DOCTYPE html&gt;
</p><h3>Step 1 : Create a basic HTML page</h3><p>A very simple HTML page looks like this:</p><pre><code class="lang-$xslt"><code class="source-code prettyprint">&lt;!DOCTYPE html&gt;
&lt;html&gt;
&lt;head&gt; &lt;/head&gt;
&lt;body&gt; &lt;/body&gt;
Expand Down
2 changes: 1 addition & 1 deletion manual/htmlTemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ We will now go through this step by step.

### Step 1 : Create a basic HTML page

A very simple html page looks like this:
A very simple HTML page looks like this:

```$xslt
<!DOCTYPE html>
Expand Down

0 comments on commit 4ee748e

Please sign in to comment.