Skip to content

Commit

Permalink
add sync effect for development and testing
Browse files Browse the repository at this point in the history
  • Loading branch information
dmaskasky committed Feb 4, 2025
1 parent 80f0472 commit 2b389ed
Show file tree
Hide file tree
Showing 4 changed files with 1,357 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/test-multiple-builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
sed -i~ "s/resolve('\.\/src\(.*\)\.ts')/resolve('\.\/dist\1.js')/" vitest.config.mts
sed -i~ "s/import { useResetAtom } from 'jotai\/react\/utils'/const { useResetAtom } = require('..\/..\/..\/dist\/react\/utils.js')/" tests/react/utils/useResetAtom.test.tsx
sed -i~ "s/import { RESET, atomWithReducer, atomWithReset } from 'jotai\/vanilla\/utils'/const { RESET, atomWithReducer, atomWithReset } = require('..\/..\/..\/dist\/vanilla\/utils.js')/" tests/react/utils/useResetAtom.test.tsx
perl -i~ -0777 -pe "s/import {[^}]+} from 'jotai\/vanilla\/internals'/const { INTERNAL_buildStore, INTERNAL_createStoreArgs, INTERNAL_initializeStoreHooks, INTERNAL_getStoreArgsRev1: INTERNAL_getStoreArgs } = require('..\/..\/dist\/vanilla\/internals.js')/g" tests/vanilla/store.test.tsx tests/vanilla/derive.test.tsx tests/vanilla/effect.test.ts
perl -i~ -0777 -pe "s/import {[^}]+} from 'jotai\/vanilla\/internals'/const { INTERNAL_buildStore, INTERNAL_createStoreArgs, INTERNAL_initializeStoreHooks, INTERNAL_getStoreArgsRev1: INTERNAL_getStoreArgs, INTERNAL_createBuildingBlocksRev1: INTERNAL_createBuildingBlocks } = require('..\/..\/dist\/vanilla\/internals.js')/g" tests/vanilla/store.test.tsx tests/vanilla/derive.test.tsx tests/vanilla/effect.test.ts
- name: Patch for ESM
if: ${{ matrix.build == 'esm' }}
run: |
Expand Down
Loading

0 comments on commit 2b389ed

Please sign in to comment.