shared
utils
string
object
is
extension
js
tracking
string
dom
when
selection
position
iframe
event
scroll
console
node
string
project
fs
console
composerJsonSync
Type:Function
Status:beta
Since:1.0.0
Platform:node
@blackbyte.sugar.node.composer
This function simply take a package name (or ”.” for the current package) as parameter, and return the corresponding composer.json JSON content
Params
- nameOrPath”process.cwd()“String
the package name or path wanted
- settings{}TComposerVendorDirSettings
Some settings to configure your process
Return
- -JSON
The composer.json content
Example
import { composerJsonSync } from '@blackbyte/sugar/composer`;
composerJsonSync('blackbyte/sugar');Settings
- cwdprocess.cwd()String
The directory in which you want to start the research
- monorepofalseBoolean
Specify if you are in a monorepo context
- checkExistencetrueBoolean
Specify if you want to check if the vendor dir exists
Todo
- Implement a cache strategy to avoid making same process again and againnormal
Author
- Olivier Bosselolivier.bossel@gmail.comhttps://blackbyte.space