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

feat(rich-text-types): expose RT validation helper #292

Merged
merged 2 commits into from
Dec 9, 2021

Conversation

z0al
Copy link
Member

@z0al z0al commented Dec 9, 2021

No description provided.

DanweDE
DanweDE previously approved these changes Dec 9, 2021
Copy link
Collaborator

@DanweDE DanweDE left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just one concern regarding exports, please double-check on that.

packages/rich-text-types/src/__test__/validation.test.ts Outdated Show resolved Hide resolved
packages/rich-text-types/src/inlines.ts Show resolved Hide resolved
@z0al z0al requested a review from DanweDE December 9, 2021 17:30
@z0al z0al enabled auto-merge (squash) December 9, 2021 17:31
@z0al z0al merged commit fc5a7cc into master Dec 9, 2021
@@ -24,6 +24,39 @@ const text = (value = '', args?: any) => ({
...args,
});

const topLevelBlocks = [
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's actually constants for both of these exported by this package TOP_LEVEL_BLOCKS and LIST_ITEM_BLOCKS 😆

@AlexandraKlein
Copy link

The ajv dependency causes this issue for me: #295

@MarkosKon
Copy link

I want to point out that ajv is included in the bundle (of a Gatsby app) even if I import only import { BLOCKS, MARKS } from "@contentful/rich-text-types";.

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

Successfully merging this pull request may close these issues.

4 participants