Skip to content
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

Unable to expose a schema #8

Open
leilaybnz opened this issue Oct 26, 2023 · 1 comment
Open

Unable to expose a schema #8

leilaybnz opened this issue Oct 26, 2023 · 1 comment

Comments

@leilaybnz
Copy link

Hi everyone! I've been following the tutorial successfully until I reached the Job schema. For some reason I cannot expose it. This is how my schemas index.ts code looks:

import job from "./job";
import profile from "./profile";

export const schemaTypes = [job, profile];

I have also tried to expose only the Job schema by removing the Profile from the array, but still I only see the Profile tab as shown here:
image

Any ideas? It might be something really small but I'm stuck.
Thank you in advance 🙂

@Evavic44
Copy link
Owner

Hey @leilaybnz

Question: What is the type: property of the job schema, set to?

Because only schemas set to "document" type will be displayed on the studio.

Essentially:

const job = {
  name: "job",
  title: "Job",
  type: "document", // document type
  icon: BiBriefcase,
  fields: [],
};

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants