Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fritzo/livecoder.net
A simple browser environment for coding live javascript.
https://github.com/fritzo/livecoder.net
javascript live-coding
Last synced: 3 months ago
JSON representation
A simple browser environment for coding live javascript.
- Host: GitHub
- URL: https://github.com/fritzo/livecoder.net
- Owner: fritzo
- Created: 2012-02-09T17:50:02.000Z (almost 13 years ago)
- Default Branch: master
- Last Pushed: 2014-01-21T21:54:47.000Z (about 11 years ago)
- Last Synced: 2024-10-03T12:51:58.397Z (4 months ago)
- Topics: javascript, live-coding
- Language: JavaScript
- Homepage: http://livecoder.net
- Size: 1.33 MB
- Stars: 26
- Watchers: 5
- Forks: 3
- Open Issues: 5
-
Metadata Files:
- Readme: README
Awesome Lists containing this project
README
LiveCoder.net = A simple browser environment
for coding live javascriptLanguage Extensions
vars._ A place to put persistent data
once._ A place to put functions that run once
always._ A place to put functions that run continuouslycached(f)(-) Caches value of f applied to JSON'able arguments
(useful for expensive tasks like audio synthesis)clear() Clears vars, once, always, cache, setTimeouts, canvas
using(url) Loads & caches a remote script (useful for libraries)
Coding Tools
help(-) Looks inside any object/function (great for hacking :)
print(-), Print messages to log area
error(-)assert(-,-) assert(value,message) throws an error if value is false
(see help(assert) for details & other assertions)TODO(-) TODO(message) is a placeholder for unfinished code
Graphics - using HTML5 canvas
draw A 2D canvas context (see examples)
mouseX, Current mouse coordinates in pixels
mouseYAudio - using HTML5 audio
play(-) Plays a uri from encodeWav/tone/noise/speech or the web
encodeWav(-) Encodes an array of [-1,1]-valued samples to a wav uri
tone(-), Synthesize sound and encode to wav uri
noise(-) (see examples or try help(-) for details)sampleRate, Constants in kHz (all time units are ms or kHz)
middleCSpeech - using espeak/speak.js
using('speech.js'); // load speech library first
say(text) Speaks text out loud
speech(text) Synthesizes voice and encodes to a wav uri
Keyboard Shortcuts
F1 Show language help F1
F2 Show keyboard shortcuts F2Ctrl-C Reset state, same as clear() Cmd-C
Escape Pause/continue compiling Escape
(useful for atomic edits)Ctrl-F Start searching Cmd-F
Ctrl-G Find next Cmd-G
Shift-Ctrl-G Find previous Shift-Cmd-G
Shift-Ctrl-F Replace Cmd-Option-F
Shift-Ctrl-R Replace all Shift-Cmd-Option-FCtrl-Space Autocomplete Cmd-Space
Ctrl-S Save code locally Cmd-S
Ctrl-O Open local gallery Cmd-O