First of all, thanks for taking the time to contribute!
To help you contribute to this project we have created some guidelines for our contributors.
- Terms
- What Contribution Do We Accept?
- Requesting an Feature
- Requesting Nodes
- The Build Script: how it works
- Bundled file location
- Blackprint Node and Interface Naming Conventions
- Version Conventions
- Financial Contribution
Here are some terms that we will use in this repo:
- "Technology" is used to describe a software, libraries, tool, framework, etc...
- "Engine" refers to Blackprint Engine that run on some programming language.
Any well-intentioned contribution is welcomed, for the example:
- Bug fixes
- New feature (please create issue with the use case to be reviewed first)
- Improve documentation or guidelines
- Financial contribution
- Promote and spread the words about Blackprint
- Joining the community and help other people
To request an feature, you can create an issue in the repository. Please follow these simple guidelines:
- Search for other issues already requesting the feature
- If an issue doesn't exist, create an issue with the template on GitHub Issue
- Please create separate issues for each feature
Blackprint Engine is available on some programming language. If you want to request Blackprint nodes for other technology (like library that developed by someone else) please create issue on their repository instead or ask the community.
You can use this template for start your first node for browser.
npm start
: Run development server for Blackprint (Sketch + Editor + Nodes + Engine).
This will only compile .js, .html, .scss, .sf
file extension.
- Sketch library:
/src
- Engine library:
/engine-js
- If you want to only focus on this engine, please set
compileEngineOnly
ongulpfile.js
totrue
- If you want to only focus on this engine, please set
- Editor:
/example
- Nodes:
/nodes
- Any folder with
blackprint.config.js
will be considered as Blackprint Addons and will be added to Editor automatically if it's not disabled
- Any folder with
npm run compile
: Compile, minify files, and run Babel for Blackprint (Sketch + Editor + Nodes + Engine).
This will only compile .js, .html, .scss, .sf
file extension, similar with npm start
.
You may want to see the guidelines if you want to use the Blackprint Editor.
When you run the build script above you may get these files.
- Sketch library:
/dist/blackprint.min.js
,/dist/blackprint.sf.js
and/dist/blackprint.sf.css
- Engine library:
/engine-js/dist/engine.min.js
- Editor:
/example/assets/*.js
and/example/assets/*.css
- Nodes:
/dist/*.mjs
,/dist/*.sf.mjs
,/dist/*.sf.css
The file names that has different export target:
*.sf.css
and*.sf.mjs
can only being imported/run on Browser*.mjs
is mjs module that can be imported for Deno
Currently this is for JavaScript nodes.
The node and interface should be registered with capitalized letter with slash with following format:
- Node:
LibraryName/[Category or Feature name]/NodeName
- Interface:
BPIC/LibraryName/[Category or Feature name]/NodeName
BPIC: Blackprint Interface Component
The example below
// ------ Node ------
Blackprint.registerNode('Graphics/Converter/GIF', ...);
// You can easily find and create from the Blackprint Editor from the node list.
// Create from the editor menu: Graphics -> Converter -> GIF
// Create with JS
instance.createNode('Graphics/Converter/GIF'); // instance = sketch/engine object
// ------ IFace ------
Blackprint.registerInterface('BPIC/Graphics/Converter/GIF', ...);
// Blackprint will create the DOM Element with lowercased tag name: <bpic-graphics-converter-gif>
// Get the iface from the DOM
let iface = $('bpic-graphics-converter-gif')[0].model;
let node = iface.node;
// Get the iface from the engine instance
let myNode = instance.iface[id];
Blackprint haven't follow semantic versioning before v1.0.0, you will need to specify the fixed version when using Blackprint Engine or Sketch library to avoid breaking changes.
The version naming follows the rules of given a version number vMAJOR.MINOR.PATCH, increment the:
MAJOR version will stay 0 until all roadmap has been completed.
MINOR version may has new feature or possible breaking changes.
PATCH version when you add functionality and bug fixes that backwards compatible.
A new release will be published when new feature are added or a bug was fixed. If the minor version is updated, please see the CHANGELOG.md to make sure the breaking changes doesn't affect your project.
Blackprint is a MIT licensed open source project and completely free to use.
However, the amount of effort needed to maintain and develop new features for the project is not sustainable without proper financial backing.
You can support Blackprint development financially from the link on repository's Sponsor button.