Socket
Socket
Sign inDemoInstall

custom-jeans

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

custom-jeans

manages custom code for geenee templates


Version published
Weekly downloads
23
increased by109.09%
Maintainers
1
Weekly downloads
 
Created
Source

manages custom code for geenee templates custom-jeans

Version Downloads/week License

This package works with geenee templates. If you want to generate a template, you can call the geenee cli. Or, you can use the geenee-spell package to handle a complete regeneration within node.

Usage

Include the package:

npm i custom-jeans

Normally, you call storeCustomCode before making programmatic changes, and then insertCustomCode afterward.

const {storeCustomCode, insertCustomCode} = require('custom-jeans')

(async () => {
	const customCode = await storeCustomCode(
      codeDir, config
    )
    
    // more code...

    const customCodeDoc = `${codeDir}/meta/customCode.json`

	await insertCustomCode(
      codeDir, customCodeDoc, config
    )

})();

StoreCustomCode

An async function that takes a rootDir ROOT_DIR and a config Configuration (a type exposed in magicalstrings) and returns a customCode json. Further, the function stores the custom code json in the file ROOT_DIR/meta/customCode.json.

InsertCustomCode

An async function that takes a rootDir ROOT_DIR, an addedCodeDoc ADDED_CODE_DOC and a config Configuration (a type exposed in magicalstrings) and will insert the custom changes where they belong within ROOT_DIR.

The value of customCodeDoc is normally ROOT_DIR/meta/customCode.json, but of course can be replaced if you want to manipulate a copy or generate it directly.

Keywords

FAQs

Package last updated on 13 Jan 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

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