mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-23 03:42:27 +03:00
103672ef57
fix https://linear.app/tryghost/issue/SLO-190/error-no-dispatch-method-detected-did-you-embed-your-app-with - we've spuriously been seeing `No dispatch method detected, did you embed your app with NiceModal.Provider` when browsing to a URL that loads a modal in Safari - it looks like DesignSystemProvider (via DesignSystemApp) contains the NiceModal.Provider, but this is loaded within the RoutingProvider that could trigger a modal to load - I tried switching around RoutingProvider and DesignSystemApp but many other tests failed, so my fix here is to add a NiceModal.Provider to wrap the RoutingProvider - unfortunately, this bug is flaky to occur and I've only been able to reproduce it on Safari, so writing a test for this would be very tricky |
||
---|---|---|
.. | ||
src | ||
test | ||
.eslintignore | ||
.eslintrc.cjs | ||
.yarnrc | ||
index.html | ||
node-shim.cjs | ||
package.json | ||
playwright.config.mjs | ||
postcss.config.cjs | ||
README.md | ||
tailwind.config.cjs | ||
tsconfig.json | ||
vite.config.mjs |
Admin X Settings
Ghost Admin Settings in React
Development
Pre-requisites
- Run
yarn
in Ghost monorepo root
Running the development version
Run yarn dev
to start the development server to test/develop the settings standalone. This will generate a demo site from the index.html
file which renders the app and makes it available on http://localhost:5173
Running inside Admin
Run yarn dev
(like you would run Ghost dev normally) from the top-level repo. AdminX will automatically rebuild when you make changes.
Develop
This is a monorepo package.
Follow the instructions for the top-level repo.
git clone
this repo &cd
into it as usual- Run
yarn
to install top-level dependencies.
Test
yarn lint
run just eslintyarn test:acceptance
runs acceptance testsyarn test:unit
runs unit testsyarn test:acceptance path/to/test
runs a specific testyarn test:acceptance:slowmo
runs acceptance tests in slow motion and headed mode, useful for debugging and developing tests