New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@graphql-markdown/docusaurus

Package Overview
Dependencies
Maintainers
0
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@graphql-markdown/docusaurus - npm Package Versions

1245

1.20.2

Diff
edno
published 1.20.2 •

Changelog

Source

1.20.2 - 2023-07-07

:sparkles: New option printTypeOptions.codeSection and CLI flag --noCode for hiding the codeblock section, based on an initial request from @ris314 in #895. See documentation for more information.

Screenshot 2023-07-07 at 16-28-08 AddCourse GraphQL-Markdown

What's Changed

edno
published 1.20.1 •

Changelog

Source

1.20.1 - 2023-07-06

What's Changed

:package: Update compatibility with prettier v3 when using pretty setting. :magic_wand:

edno
published 1.20.0 •

Changelog

Source

1.20.0 - 2023-07-01

:sparkles: GraphQL Config is now supported, see the documentation for more information and limitations :rocket:

This is the default set up when creating a new site using the template.

First install the package graphql-config, then you are ready to go.

npm install graphql-config

Example .graphqlrc:

schema: "https://graphql.anilist.co/"
extensions:
  graphql-markdown:
    linkRoot: "/examples/default"
    baseURL: "."
    homepage: "data/anilist.md"
    loaders:
      UrlLoader:
        module: "@graphql-tools/url-loader"
        options: 
          method: "POST"
    printTypeOptions:
      deprecated: "group"
    docOptions:
      pagination: false
      toc: false

What's Changed

edno
published 1.19.0 •

Changelog

Source

1.19.0 - 2023-06-03

:warning: This release introduces minor breaking changes, see section breaking changes.

:label: Building upon customDirective released in 1.18.0, we added a new option tag that allows one to display custom badges (tags) in the documentation pages.

The feature is an extension of the customDirective by using the already available directive processing. It works the same way as descriptor, and it also comes with an helper directiveTag... more details in the documentation.

  customDirective: {
    beta: {
      tag: (directive) => ({
        text: directive?.name.toUpperCase(),
        classname: "badge--danger",
      }),
    },

Screenshot from 2023-06-03 11-27-49

Screenshot from 2023-06-03 11-28-21

Breaking changes

  • Since tags have now a dedicated handler, the directives declared in customDirective for descriptor won't display a badge. A helper helper.directiveTag is provided for backward compatibility. Users who want to keep the previous behavior just need to declare tag: helper.directiveTag for each directive declared.

    const { helper } = require("@graphql-markdown/utils");
    
    //---//
      auth: {
          descriptor: (directive, type) =>
            helper.directiveDescriptor(
              directive,
              type,
              "This requires the current user to be in `${requires}` role.",
            ),
          tag: helper.directiveTag,
        },
    
  • The deprecated "warning badge" has been changed into an admonition for a clearer UI.

    Screenshot from 2023-06-03 08-22-06

  • Last change is the change of position of the custom directive descriptions that are now after the type description instead of before.

    Screenshot from 2023-06-03 11-25-14

What's Changed

edno
published 1.18.2 •

Changelog

Source

1.18.2 - 2023-06-01

:sparkle: Add wildcard * support for customDirective, more details in the documentation.

What's Changed

edno
published 1.18.1 •

Changelog

Source

1.18.1 - 2023-05-07

:bug: Fix missing code indentation for fields in some cases (#850) by @ljiang-ti in #851.

What's Changed

edno
published 1.18.0 •

Changelog

Source

1.18.0 - 2023-05-05

:star_struck: A new really cool feature by @ljiang-ti, customDirective provides documentation of schema directives at type level. One can now choose to print a custom description for schema directives applying to a type or field. :sparkles:

:point_right: ~There is a open discussion for this feature, and the possible improvements.~

plugins: [
  [
    "@graphql-markdown/docusaurus",
    {
      // ... other options
      customDirective: {
        auth: {
          descriptor: (directive, type) =>
            directiveDescriptor(
              directive,
              type,
              "This requires the current user to be in `${requires}` role.",
            ),
        },
        // ... other custom directive options
      },
    },
  ],
],

Screenshot from 2023-05-05 10-21-14

If you want to see it live, the group-by example documentation has been updated to showcase the feature.

You can find more examples and information regarding helpers to get you started in the documentation.

What's Changed

edno
published 1.17.3 •

Changelog

Source

1.17.3 - 2023-04-20

Fix the issue when an operation and a type have the same name with the feature groupByDirective, reported in #831 :bug:

What's Changed

edno
published 1.17.2 •

Changelog

Source

1.17.2 - 2023-04-17

Fix issue on schema loader options (#815) by @chmanie 🐛

What's Changed

edno
published 1.17.1 •

Changelog

Source

1.17.1 - 2023-04-16

🐞 Fix some inconsistencies when handling @deprecated directive:

  • @deprecated is now printed in code snippets for a better visibility
  • printDeprecated: "skip" skips all deprecated types, including types in code snippets and metadata (fields, enum values)

What's Changed