Socket
Book a DemoInstallSign in
Socket

@dmn-arc-core-components/tools_mock-ans

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dmn-arc-core-components/tools_mock-ans

### What is this?

latest
Source
npmnpm
Version
1.0.0-alpha
Version published
Maintainers
1
Created
Source

Mock ANS for Core Components

What is this?

Mock ANS is an npm package that you can use to quickly mock ANS objects for rapid development with Core Components.

It is designed to match up with the ANS Schema.

All of the content is generated using various npm packages, so nothing is secret, and some of it is kind of fun!

It is particularly useful for mocking up the docz portions of Core Components.

How do I use it?

Within your project repo:

npm install @dmn-arc-core-components/mock-ans

And in any JS files where you want an ANS object:

import { Story } from "@dmn-arc-core-components/mock-ans";

const myCoolANS = new Story();

What if I want to pass in some specific stuff, like websites, etc?

Currently, you can pass in an object with a key of website to specify what websites this ANS should be part of, like this:

const myCoolANSStoryWithASpecificWebsite = new Story({
  website: "my-ans-website"
});

More support might be added for this functionality, as we go along.

What else would you do with this package, if you had time?

  • I'd really like to add the ANS Validator, to ensure that all our ANS is in great shape.
  • This currently doesn't support all ANS types, like Video or Galleries. It will, however, once those Core Components are fleshed out.
  • This has not been integrated with a Fusion project for rapid development.

FAQs

Package last updated on 05 Nov 2021

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