I discovered your project a few days ago and instantly got in love with what you are doing! I've been developing game prototypes in Javascript for a while (hobbies mainly) and music/sound FXs have always been a pain to handle.
I just forked your project and noticed there are a few development features installed but unused, or with virtually no config and thought I could help there, so here's my pull request, your code is virtually untouched (linted and on a different folder tho')... aside from the tempo function, which I added.
Here's the list of changes I'm sending:
Code reorganization:
/src all of the code is here now, just to make the root folder a bit more clean
/src/static this is the old /public folder, the previous structure contained a mix of editable and generated files, now we have all of the editable code on a single folder.
/dist (GIT ignored) contains all of the files generated (or cloned) by Webpack. This folder is ignored on the repo because it's created when starting npm start or building npm build the project. Not we have all of the built files on it's own folder.
/package folder: which contains webpack config and dev server.
Activating and applying AirBnB Lint: I noticed you have this lint on the package.json but it was not imported on .eslint . I added the import and linted the whole code... yes the whole code.
Removed slang_grammar.js: You already have a slang.ohm with the exact same content, so why not use that file and load it through Webpack?
Added a few scripts to the package.json: Now you can lint, generate /dist and start a dev server with watch enabled using npm start. Also added npm lint, and splitted npm run dev:webpack and npm run dev:server. Just in case you wanted to run them independently. build was pimped a little bit too.
Added the 'tempo' function: My first real contribution to the project, just a simple function that let's you set the beats per second. Default s 120. It affects all of the following play functions so we can do this:
tempo 120
play @synth1
tempo 240
play @synth2
I really hope I can contribute on this project, maybe someday we can achieve something like JSX, but for music and sounds.
Hi there!
I discovered your project a few days ago and instantly got in love with what you are doing! I've been developing game prototypes in Javascript for a while (hobbies mainly) and music/sound FXs have always been a pain to handle.
I just forked your project and noticed there are a few development features installed but unused, or with virtually no config and thought I could help there, so here's my pull request, your code is virtually untouched (linted and on a different folder tho')... aside from the
tempo
function, which I added.Here's the list of changes I'm sending:
npm start
or buildingnpm build
the project. Not we have all of the built files on it's own folder.npm start
. Also addednpm lint
, and splittednpm run dev:webpack
andnpm run dev:server
. Just in case you wanted to run them independently.build
was pimped a little bit too.play
functions so we can do this:I really hope I can contribute on this project, maybe someday we can achieve something like JSX, but for music and sounds.
Cheers!