-
Notifications
You must be signed in to change notification settings - Fork 41
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
Split components into seperate packages #411
Conversation
Everything now works for build & test scripts. Now to figure out how to get |
f8df726
to
6e55714
Compare
6e55714
to
a9aaa06
Compare
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.
Looks good to me
@@ -3,7 +3,7 @@ | |||
import { DefinedError, ErrorObject } from "ajv"; | |||
import path from "path"; | |||
import { inspect } from "util"; | |||
import { ajv, validate } from "../payload-schemas"; | |||
import { ajv, validate } from "../payload-schemas/index"; |
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.
import { ajv, validate } from "../payload-schemas/index"; | |
import { ajv, validate } from "../payload-schemas"; |
nit: node imports index
if it exists when you tell it to import a folder, meaning you can leave this file as is.
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.
Yes, it usually does, but in this case, since there's a package.json
in the directory with a main
property, it'll use the main
property which in this case is schema.json
.
Which is why I used an explicit import instead of implicit
This reverts commit 64f5450.
Node (tested on v14) would use the file listed in the `main` field in `package.json` for the import, which is the `schema.json` file in this case, while we wanted the `index.ts` file
Also it looks like the README has not yet been updated. What should the 3 packages be? Can we put them in 3 different directories, and have a |
I'll update the README
They already are seperated, only the global package is
For sure, that can be done. |
98e1ee2
to
d7ff69a
Compare
I have found this |
I didn't use that plugin myself, but it sounds like it supports different versions for the different packages in the repository, which is not something we need in our case. I think we could use semantic-release for the root ( |
The changes are made.
|
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.
Looks good to me 👍
🎉 This PR is included in version 3.67.0-beta.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎉 This PR is included in version 3.68.0-beta.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
It appears as though, it's not publishing the other packages.
|
There is 2 issues here currently:
|
I’ll have a look ASAP, tonight or tomorrow |
I don't think this solution for publishing packages will work as is. |
🎉 This PR is included in version 3.68.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
As per our discussion in #362, I started refactoring the repository to move the 3 components of this repo (examples, schemas, types) into seperate packages.
All the build scripts work, all test scripts work except for the
validate
script