-
-
Notifications
You must be signed in to change notification settings - Fork 344
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update examples to run independently #318
Conversation
- All examples are now completely standalone (hopefully this helps with people wanting to use them without running/building pact js) - Examples are `npm link`ed during build, to ensure they are still testing the current build
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I love this! Great improvement.
A few small things:
-
Snyk complains about the examples. I wonder if we can/should prevent it from checking them?
-
I hadn't realised the graphql example is written in typescript - a quick glance suggests there's a fair bit of extra config that's unrelated to the example. Should we change this in a later commit?
-
Some of the bash changes are missing
"
, and for robustness, it's probably worth covering if the glob doesn't match (I'll push a commit fixing these).
Thanks.
|
fc4c906
to
5d0d349
Compare
Currently, all of the examples run with the implicit parent package scope, as well as requiring a compiled build of pact-js to run (i.e. a
npm run dist
in the root directory).This makes it difficult for newcomers to navigate to an example and run independently, or to use as a basic for a project because the dependencies are not made clear.
This change does the following:
npm link
so that all examples in the repository are still tested against the current build of Pact JS / Pact Web, to prevent bugs/regressions