0.26.1 • Published 7 years ago

stencila-node-0.26.0 v0.26.1

Weekly downloads
2
License
Apache-2.0
Repository
github
Last release
7 years ago

Stencila for Node.js

NPM Build status Code coverage Dependency status Chat

Install

npm install stencila-node

Use

This package lets you run JavaScript code from inside Stencila Documents. First, you need to start serving the Stencila Host within this package. You can do that from inside Node.js:

const stencila = require('stencila-node')
stencila.host.start()

Or from the shell,

./node_modules/.bin/stencila-node

This will serve a Stencila Host on localhost. You can then open your Stencila Document from within the Stencila Desktop. The host will be automatically detected by the desktop app and you'll be able to execute Javascript code cells from within your documents.

More documentation is available at https://stencila.github.io/node.

Discuss

We love feedback. Create a new issue, add to existing issues or chat with members of the community.

Develop

Most development tasks can be run directly from npm or via make wrapper recipes.

Tasknpm et almake
Install and setup dependenciesnpm installmake setup
Check code for lintnpm run lintmake lint
Run testsnpm testmake test
Run tests with coveragenpm run covermake cover
Build documentationnpm run docsmake docs
Serve and watch docs for updatesnpm run docs-servemake docs-serve
Cleanmake clean

To get started, please read our contributor code of conduct, then get in touch, checkout the platform-wide, cross-repository kanban board or just send in a pull request!

Docs are published using Github Pages, so to update them after making changes run make docs, commit the updated docs and do a git push.

Tests are run on Travis and code coverage tracked at Codecov.