Thank you for your interest in contributing to Flowscape.
Flowscape is an open-source 2D engine for building infinite canvas applications, design tools, visual builders, whiteboards, diagram editors, and other graphical products.
Contributions of all kinds are welcome, including bug fixes, performance improvements, documentation updates, tests, new features, and architectural discussions.
Flowscape is developed as a monorepo using:
Clone the repository:
git clone https://github.com/Flowscape-UI/core-sdk.git
cd core-sdkInstall dependencies:
bun installThe repository is organized as a monorepo:
flowscape/
├── apps/
│ ├── docs/
│ └── playground/
│
├── packages/
│ └── engine/
│
├── package.json
├── turbo.json
└── bun.lock
The interactive development environment for Flowscape.
The Playground should consume the engine through its public package API:
import { Scene, NodeRect } from "@flowscape-ui/core-sdk";It should not import directly from internal engine source files.
The documentation application for Flowscape.
Documentation for public APIs, concepts, and usage examples belongs here.
The main Flowscape engine.
This package is published as:
@flowscape-ui/core-sdk
Core engine logic, scene architecture, nodes, renderers, input systems, and other engine-level functionality live here.
bun run dev:playgroundUse the Playground when developing or testing engine functionality.
Changes to the engine should be tested through the public package API whenever possible.
bun run dev:docsbun run devThis runs the available dev tasks across the monorepo through Turborepo.
Build the entire monorepo:
bun run buildBuild only the Playground:
bun run build:playgroundBuild only the documentation:
bun run build:docsTurborepo automatically resolves dependencies between workspace packages and runs required build tasks in the correct order.
Run TypeScript checks across the repository:
bun run typecheckAll TypeScript errors should be resolved before submitting a pull request.
Run lint checks:
bun run lintPlease avoid introducing new lint errors or warnings.
Format the repository with Prettier:
bun run formatCheck formatting without modifying files:
bun run format:checkRun the test suite:
bun run testChanges that affect engine behavior should include tests when practical.
Bug fixes should preferably include a regression test that demonstrates the issue being fixed.
Flowscape has a clearly defined public API.
Consumers should import from:
import { Scene, NodeRect } from "@flowscape-ui/core-sdk";Do not rely on internal paths such as:
import { Scene } from "@flowscape-ui/core-sdk/src/scene";Internal modules may change without notice.
When adding functionality intended for Flowscape users, make sure it is exported through the public entry point:
packages/engine/src/index.ts
Before introducing or changing a public API, consider:
- Is the API necessary?
- Is the naming consistent with existing Flowscape APIs?
- Can the functionality be extended later without breaking users?
- Does the change introduce a breaking change?
- Should the behavior be documented?
Public API stability is important for Flowscape.
Avoid breaking existing APIs unless the change is intentional and appropriate for a major release.
Flowscape separates scene state, rendering, and interaction systems.
At a high level:
Scene
├── Background Layer
├── World Layer
│ └── Nodes
├── Overlay Layer
│ └── Handles / Selection / Transformations
└── UI Layer
When contributing to the engine, try to preserve architectural boundaries.
For example:
- Scene logic should not depend unnecessarily on a specific rendering backend.
- Renderer implementations should remain separate from core node state.
- Input logic should remain separated from rendering where practical.
- Applications such as the Playground should not access engine internals directly.
- New functionality should have a clear ownership area within the engine.
Large architectural changes should preferably be discussed before implementation.
Dependencies should be added to the workspace that actually uses them.
For example, a dependency used only by the engine belongs in:
packages/engine/package.json
A dependency used only by the Playground belongs in:
apps/playground/package.json
Avoid adding package-specific dependencies to the root package.json.
The root package should primarily contain tooling used to manage the monorepo itself.
Keep commits focused and descriptive.
Examples:
fix: correct ellipse hit testing
feat: add renderer abstraction for gradients
refactor: simplify overlay interaction ownership
docs: update Scene API documentation
test: add NodePath resize regression test
A single commit should ideally represent one logical change.
Avoid mixing unrelated refactoring, formatting, and feature work into the same commit when possible.
Before opening a pull request:
- Make sure the project builds successfully.
- Run type checking.
- Run linting.
- Run tests.
- Test relevant changes in the Playground.
- Update documentation if the public API or behavior changed.
- Update the changelog when appropriate.
Recommended checks:
bun run build
bun run typecheck
bun run lint
bun run testA pull request should clearly explain:
- What changed
- Why the change was necessary
- How the change was tested
- Whether the public API changed
- Whether the change is backward compatible
Screenshots or recordings are encouraged for visual or interaction-related changes.
When reporting a bug, please include as much relevant information as possible:
- Flowscape version
- Browser and operating system
- Steps to reproduce
- Expected behavior
- Actual behavior
- Minimal reproduction when possible
- Screenshots or recordings for visual issues
For rendering or interaction bugs, a small reproduction in the Playground is especially useful.
Feature requests are welcome.
Please describe:
- The problem you are trying to solve
- The proposed behavior
- Why the feature belongs in the engine rather than application-level code
- Possible alternatives
- Any expected impact on the public API
Flowscape is intended to remain a flexible engine rather than a collection of application-specific features.
New features should generally provide reusable foundations that can benefit multiple types of graphical applications.
Breaking changes require extra care.
Before introducing one, consider whether the same goal can be achieved through:
- a new API
- deprecation
- an adapter
- backward-compatible behavior
When a breaking change is necessary, it should be clearly documented and included in the appropriate release notes and changelog.
Notable user-facing changes should be documented in:
CHANGELOG.md
During development, changes may be added under:
## [Unreleased]Examples of changes worth documenting:
- New public APIs
- New engine capabilities
- Breaking changes
- Significant architecture changes
- Important bug fixes
- Performance improvements
Internal refactoring with no observable impact usually does not require a changelog entry.
Public features should be documented.
Documentation should explain:
- What the feature does
- Why it exists
- How to use it
- Important limitations
- Relevant examples
Simple examples are preferred over unnecessarily complex ones.
The README should remain focused on project introduction and quick start.
Detailed engine documentation belongs in:
apps/docs
Flowscape aims to be:
- predictable
- extensible
- framework-agnostic
- renderer-independent where possible
- strongly typed
- suitable for large editor applications
Prefer clear architecture over clever abstractions.
Prefer APIs that remain understandable without knowledge of internal implementation details.
Avoid introducing abstractions before they solve a real problem.
For larger architectural proposals or significant changes, opening an issue or discussion before implementing the full solution is encouraged.
This helps ensure that the proposed direction fits the long-term architecture of Flowscape.
By contributing to Flowscape, you agree that your contributions will be licensed under the project's MIT License.
Thank you for helping improve Flowscape.