Skip to content

Commit 9edfe83

Browse files
authored
update dependencies and modernize project (#17)
1 parent 9cafd2c commit 9edfe83

File tree

9 files changed

+4948
-3877
lines changed

9 files changed

+4948
-3877
lines changed

.circleci/config.yml

Lines changed: 0 additions & 30 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: ["**"]
6+
pull_request:
7+
8+
jobs:
9+
build-and-test:
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: read
13+
checks: write
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
18+
- name: Setup Node.js
19+
uses: actions/setup-node@v4
20+
with:
21+
node-version: 22
22+
cache: npm
23+
24+
- name: Install dependencies
25+
run: npm ci
26+
27+
- name: Build
28+
run: npm run build
29+
30+
- name: Run tests
31+
run: npm run test:ci
32+
33+
- name: Publish test results
34+
if: always()
35+
uses: dorny/test-reporter@v1
36+
with:
37+
name: Test Results
38+
path: junit.xml
39+
reporter: jest-junit
40+
fail-on-error: false

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# @subshell/data-repositories
22

3-
[![CircleCI](https://circleci.com/gh/subshell/data-repositories.svg?style=svg)](https://circleci.com/gh/subshell/data-repositories) [![npm version](https://badge.fury.io/js/%40subshell%2Fdata-repositories.svg)](https://badge.fury.io/js/%40subshell%2Fdata-repositories)
3+
[![CI](https://github.com/subshell/data-repositories/actions/workflows/ci.yml/badge.svg)](https://github.com/subshell/data-repositories/actions/workflows/ci.yml) [![npm version](https://badge.fury.io/js/%40subshell%2Fdata-repositories.svg)](https://badge.fury.io/js/%40subshell%2Fdata-repositories)
44

5-
This is a wrapper around [Dexie](https://github.com/dfahlander/Dexie.js), which itself is already a wrapper around IndexedDB. This wrapper allows to create
5+
This is a wrapper around [Dexie](https://github.com/dexie/Dexie.js), which itself is already a wrapper around IndexedDB. This wrapper allows to create
66
repository classes, similar as you might be used to from Java and Spring Data.
77

88
Short example of a repository:
@@ -28,7 +28,7 @@ class Person {
2828

2929
class PersonRepository extends AbstractRepository<Person, string> {
3030
constructor() {
31-
super(new DatabaseAccess(PersonRepository.name), Person);
31+
super(DatabaseAccess.get(PersonRepository.name), Person);
3232
}
3333
}
3434

jest.config.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */
2-
module.exports = {
2+
const config = {
33
preset: 'ts-jest',
44
testEnvironment: 'jsdom',
55
rootDir: 'test',
@@ -8,3 +8,5 @@ module.exports = {
88
"^dexie$": require.resolve("dexie"),
99
}
1010
};
11+
12+
module.exports = config;

0 commit comments

Comments
 (0)