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

@focus-reactive/graphql-content-layer

Package Overview
Dependencies
Maintainers
0
Versions
135
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@focus-reactive/graphql-content-layer

[![npm version](https://badge.fury.io/js/%40focus-reactive%2Fgraphql-content-layer.svg)](https://badge.fury.io/js/%40focus-reactive%2Fgraphql-content-layer) # GitNation GraphQL Content Layer

  • 3.2.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

npm version

GitNation GraphQL Content Layer

package for fetching conference content from GraphCMS

it's published on NPM as

@focus-reactive/graphql-content-layer

This package is intended for:

  1. Fetching data from GraphCMS, process and building content layer
  2. Generate Storybook with output of:
    1. GraphCMS queries (CMS Layer)
    2. Processed content (Content Layer)

API and Configuring

  1. GraphCMS connection should be configured via env variables: CMS_ENDPOINT and CMS_TOKEN

  2. The package exposes getContent async function for generating content layer

Usage:

const { getContent } = require('@focus-reactive/graphql-content-layer');

const content = await getContent(conferenceSettings);

see conferenceSettings for details

  1. The package generates Storybook with CMS and Content layers

to use it:

// story.js

const {
  passConferenceSettings,
} = require('@focus-reactive/graphql-content-layer/dist/content.stories');

passConferenceSettings(conferenceSettings);

conferenceSettings

Pass conferenceSettings with conference specific ("hardcoded") data

I should contain:

tagColors - colors settings for "tech" badges, tags, labels

speakerAvatar = {
 dimensions: {
   avatarWidth: 500,
   avatarHeight: 500,
 }
}
  • image transformation settings for speakers/trainers/mcs and so on avatars

Develop

yarn dev to start watching and compiling the code

yarn storybook to launch Storybook

yarn tdd - Jest tests in watching mode

yarn start - starts dev, storybook and tests (each in independent watch mode)

yarn update-schema for updating GraphQL introspection schema

For publishing to NPM:

npm publish

it will transpile the code and publish the package

Keywords

FAQs

Package last updated on 19 Dec 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc