diff options
Diffstat (limited to 'guide-src/development')
-rw-r--r-- | guide-src/development/index.html | 27 | ||||
-rw-r--r-- | guide-src/development/js-features.html | 22 |
2 files changed, 49 insertions, 0 deletions
diff --git a/guide-src/development/index.html b/guide-src/development/index.html new file mode 100644 index 0000000..717ff6d --- /dev/null +++ b/guide-src/development/index.html @@ -0,0 +1,27 @@ +--- getting started + +<p> +note: this section is only for people who want to contribute to pugl itself. +</p> + +<p> +after cloning the <a href="https://github.com/pommicket/pugl" target="_blank">repository</a>, +make sure you run +<pre><code>npm install +ln -s ../../pre-commit .git/hooks/</code></pre> + +this ensures that your changes are prettified & linted. +</p> + +<p> +the main files of interest are <code>index.html</code> and <code>pugl.js</code>, which has all +the JavaScript for pugl (hopefully it doesn't become too unmanageable to have just one file). +</p> + +<h3>contributing to the guide</h3> +<p> +the guide is automatically generated from the files in <code>guide-src/</code> by <code>guide-src/make.py</code> +(you can also just run <code>make</code> to generate it), which is a simple script whose main purpose is adding +a sidebar to all of the guide pages. any PNG files are automatically copied from <code>guide-src/</code> to <code>guide/</code>. +when you add or remove pages from the guide, you'll need to edit <code>guide-src/outline.txt</code>. +</p> diff --git a/guide-src/development/js-features.html b/guide-src/development/js-features.html new file mode 100644 index 0000000..ea8ac97 --- /dev/null +++ b/guide-src/development/js-features.html @@ -0,0 +1,22 @@ +--- modern JavaScript features + +<p> +pugl has no dependencies, and i'd like to keep it that way. +</p> + +<p> +i've been pretty liberal about using modern javascript; +even though this could in theory run on IE it doesn't +(in particular it's very nice to have template literals). +that said, try to only use features that have at least as much +support as webgl2 (i.e. >94%). +</p> + +<p> +we use webgl2 because: +<ul> + <li>having non-constant loops in shaders is nice</li> + <li>there aren't that many browsers that support webgl and ES6 but not webgl2 (looking at caniuse.com, they probably + make up around 2% of browser usage)</li> +</ul> +</p> |