Skip to content

Commit 2aebf77

Browse files
committed
Import jsonld-tools history into history/jsonld-tools/
2 parents b3c6509 + 36ddc43 commit 2aebf77

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+16533
-0
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
* text=auto
2+
*.js text eol=lf
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: run tests
2+
on:
3+
push:
4+
workflow_dispatch:
5+
6+
jobs:
7+
container-job:
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- name: Checkout repository
12+
uses: actions/checkout@v4
13+
14+
- uses: pnpm/action-setup@v4
15+
name: Install pnpm
16+
with:
17+
version: 10
18+
run_install: false
19+
20+
- name: Install Node.js
21+
uses: actions/setup-node@v4
22+
with:
23+
node-version: 20
24+
cache: 'pnpm'
25+
26+
- name: Install dependencies
27+
run: pnpm install
28+
29+
- name: Build packages
30+
run: pnpm build
31+
32+
- name: Run tests for jsonld-tools
33+
run: cd ./packages/jsonld-tools && pnpm test

history/jsonld-tools/.gitignore

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
# Dependencies
2+
node_modules/
3+
**/node_modules/
4+
5+
# Build outputs
6+
dist/
7+
build/
8+
packages/**/dist/
9+
packages/**/build/
10+
*.tsbuildinfo
11+
12+
# Logs
13+
*.log
14+
npm-debug.log*
15+
yarn-debug.log*
16+
yarn-error.log*
17+
pnpm-debug.log*
18+
lerna-debug.log*
19+
20+
# Runtime data
21+
pids
22+
*.pid
23+
*.seed
24+
*.pid.lock
25+
26+
# Coverage directory used by tools like istanbul
27+
coverage/
28+
*.lcov
29+
30+
# nyc test coverage
31+
.nyc_output
32+
33+
# Dependency directories
34+
jspm_packages/
35+
36+
# Optional npm cache directory
37+
.npm
38+
39+
# Optional eslint cache
40+
.eslintcache
41+
42+
# Optional REPL history
43+
.node_repl_history
44+
45+
# Output of 'npm pack'
46+
*.tgz
47+
48+
# Yarn Integrity file
49+
.yarn-integrity
50+
51+
# dotenv environment variables file
52+
.env
53+
.env.local
54+
.env.development.local
55+
.env.test.local
56+
.env.production.local
57+
58+
# parcel-bundler cache (https://parceljs.org/)
59+
.cache
60+
.parcel-cache
61+
62+
# Next.js build output
63+
.next
64+
out
65+
66+
# Nuxt.js build / generate output
67+
.nuxt
68+
dist
69+
70+
# Gatsby files
71+
.cache/
72+
public
73+
74+
# Storybook build outputs
75+
.out
76+
.storybook-out
77+
78+
# Temporary folders
79+
tmp/
80+
temp/
81+
82+
# Editor directories and files
83+
.vscode/
84+
.idea/
85+
*.swp
86+
*.swo
87+
*~
88+
89+
# OS generated files
90+
.DS_Store
91+
.DS_Store?
92+
._*
93+
.Spotlight-V100
94+
.Trashes
95+
ehthumbs.db
96+
Thumbs.db
97+
98+
# TypeScript
99+
*.tsbuildinfo
100+
101+
# Testing
102+
coverage/
103+
.nyc_output/
104+
105+
# Misc
106+
*.tgz
107+
*.tar.gz

history/jsonld-tools/LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2025 Dan Lynch <[email protected]>
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

history/jsonld-tools/PUBLISHING.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
## publishing
2+
3+
```sh
4+
pnpm dlx lerna version patch
5+
pnpm build
6+
pnpm -r publish
7+
```

history/jsonld-tools/README.md

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
# JSON-LD Tools
2+
3+
A monorepo containing powerful JSON-LD processing tools and utilities.
4+
5+
## Overview
6+
7+
This repository provides a comprehensive set of tools for working with JSON-LD data, including advanced filtering, graph processing, and configuration management capabilities.
8+
9+
## Packages
10+
11+
### [`jsonldjs`](./packages/jsonld-tools)
12+
13+
A powerful, generic JSON-LD builder with comprehensive entity and property filtering capabilities. Features include:
14+
15+
- **Configuration-First Design**: Separate immutable configuration from graph processing
16+
- **Fluent Interface**: Chainable methods for building complex filtering logic
17+
- **Property-Level Filtering**: Filter properties by entity IDs or types
18+
- **Subgraph Extraction**: Extract connected subgraphs with reference following
19+
- **Type Safety**: Full TypeScript support with proper type inference
20+
21+
## Quick Start
22+
23+
```bash
24+
# Install the main package
25+
pnpm add jsonldjs
26+
27+
# Basic usage
28+
import { createJsonLdBuilder } from 'jsonldjs';
29+
30+
const result = createJsonLdBuilder()
31+
.baseGraph(jsonldGraph)
32+
.includeTypes(['Organization', 'Person'])
33+
.excludeTypes(['ImageObject'])
34+
.build({ prettyPrint: true });
35+
```
36+
37+
## Development
38+
39+
### Prerequisites
40+
41+
- Node.js 16+
42+
- pnpm (recommended package manager)
43+
44+
### Setup
45+
46+
1. Clone the repository:
47+
48+
```bash
49+
git clone https://github.com/hyperweb-io/jsonld-tools.git
50+
cd jsonld-tools
51+
```
52+
53+
2. Install dependencies:
54+
55+
```bash
56+
pnpm install
57+
```
58+
59+
3. Build all packages:
60+
61+
```bash
62+
pnpm run build
63+
```
64+
65+
### Repository Structure
66+
67+
```
68+
jsonld-tools/
69+
├── packages/
70+
│ └── jsonld-tools/ # Main JSON-LD processing library
71+
├── fixtures/ # Test data and examples
72+
└── docs/ # Documentation
73+
```
74+
75+
## Documentation
76+
77+
For detailed documentation and API reference, see the individual package READMEs:
78+
79+
- [jsonldjs Documentation](./packages/jsonld-tools/README.md)
80+
81+
## License
82+
83+
MIT License - see [LICENSE](./LICENSE) file for details.
84+
85+
## Contributing
86+
87+
Contributions are welcome! Please read our contributing guidelines and submit pull requests to the main branch.

0 commit comments

Comments
 (0)