@critical-path/core 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +55 -0
  2. package/package.json +1 -1
package/README.md ADDED
@@ -0,0 +1,55 @@
1
+ # @critical-path/core
2
+
3
+ > **Core domain engine, data models, and plugin architecture for Critical Path.**
4
+
5
+ `@critical-path/core` provides the core business logic, type definitions, storage abstractions, and plugin lifecycle hooks for the [Critical Path](https://github.com/Pixerate/Critical-Path) headless project management framework.
6
+
7
+ ---
8
+
9
+ ## 📦 Installation
10
+
11
+ ```bash
12
+ npm install @critical-path/core
13
+ # or
14
+ pnpm add @critical-path/core
15
+ ```
16
+
17
+ ---
18
+
19
+ ## 🚀 Key Features
20
+
21
+ - **Domain Models**: TypeScript interfaces for `Project`, `Task`, `Sprint`, `Comment`, `Activity`, `TimeEntry`, and `CustomFieldDefinition`.
22
+ - **`CriticalPathEngine`**: Central engine that coordinates storage operations and executes plugin lifecycle hooks.
23
+ - **Storage Abstraction**: `StorageAdapter` interface for connecting custom databases (PostgreSQL, SQLite, Prisma, Drizzle) and included `InMemoryStore`.
24
+ - **Strapi-Style Plugin Architecture**: `PluginRegistry` supporting lifecycle hooks (`beforeTaskCreate`, `afterTaskUpdate`, `beforeTaskDelete`).
25
+
26
+ ---
27
+
28
+ ## 💡 Quick Example
29
+
30
+ ```ts
31
+ import { CriticalPathEngine, InMemoryStore } from '@critical-path/core';
32
+
33
+ const store = new InMemoryStore();
34
+ const engine = new CriticalPathEngine({ store });
35
+
36
+ // Create a project
37
+ const project = await engine.createProject({
38
+ key: 'MAIN',
39
+ name: 'Core Engine Roadmap'
40
+ });
41
+
42
+ // Create a task
43
+ const task = await engine.createTask({
44
+ projectId: project.id,
45
+ title: 'Setup Core Engine',
46
+ status: 'in_progress',
47
+ priority: 'high'
48
+ });
49
+ ```
50
+
51
+ ---
52
+
53
+ ## 📄 License
54
+
55
+ MIT © [Critical Path](https://github.com/Pixerate/Critical-Path)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@critical-path/core",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Core headless domain engine, plugin architecture, and data stores for Critical Path",
5
5
  "author": "Jack James",
6
6
  "license": "MIT",