Security News
pnpm 10.0.0 Blocks Lifecycle Scripts by Default
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
boiler-dev
Advanced tools
Boilerplate generator framework & low-code power tool 🛠️
npm install -g boiler-dev
Action | Command |
---|---|
Start a new TypeScript project | boiler new [project-name] |
Change directory to project | cd [project-name] |
Install and run generator | boiler generate [git url] |
Update generator | boiler update [boiler/generator-name] |
Regenerate installed generator | boiler generate [boiler/generator-name] |
Create new generator | boiler new [boiler/generator-name] |
Commit and push generator | boiler commit [boiler/generator-name] |
Status of generator repos | boiler status [boiler/generator-name] |
When commands are run without arguments, it will run across all installed generators.
For successive generate
calls, boiler will regenerate with saved user input unless the --new
flag is specified.
Path | Description |
---|---|
.boiler.json | Record of generator runs, with version and user input data |
boiler/ | Installed generator repos |
npm install -g boiler-dev
cd
to your projectboiler generate [git repo]
The generate
command automatically installs new generators.
Generator repos are cloned to the boiler
directory within your project. The boiler
directory is like node_modules
for your generators.
ℹ️ Explore example generators on the boiler-dev GitHub org.
cd
to your projectboiler update [boiler/my-generator]
boiler generate [boiler/my-generator]
cd
to your projectboiler new boiler/my-generator
boiler/my-generator/boiler.ts
(see next section for API details)boiler generate boiler/my-generator
boiler commit boiler/my-generator "First commit"
boiler.ts
Each generator repo must have a boiler.ts
or boiler.js
file:
import {
InstallBoiler,
PromptBoiler,
GenerateBoiler,
UninstallBoiler,
} from "boiler-dev"
export const install: InstallBoiler = async ({
files,
rootDirPath,
}) => {}
export const prompt: PromptBoiler = async ({
files,
rootDirPath,
}) => {
const prompts = []
return prompts
}
export const generate: GenerateBoiler = async ({
answers,
files,
rootDirPath,
}) => {
const actions = []
return actions
}
export const uninstall: UninstallBoiler = async ({
answers,
files,
rootDirPath,
}) => {}
The prompt
function returns an array of "prompts" that define user input to retrieve.
Prompts are essentially an array of Inquirer.js Questions.
The generate
function returns an array of "actions" necessary to install the boilerplate.
Actions are a convenience; feel free to run your own async code within installBoiler
and return nothing.
actions.push({
action: "write",
path: "bin/hi",
source: "#!/usr/bin/env node",
bin: true,
})
ℹ️ The
bin
option runschmod +x
on the file.
actions.push({
action: "merge",
path: "package.json",
source: { hi: true },
})
ℹ️ The merge functionality comes from deepmerge.
actions.push({
action: "npmInstall",
source: ["typescript"],
dev: true,
})
When not used within a boiler/
directory, the boiler new
command creates a new TypeScript project to kick things off:
boiler new my-project
ℹ️ This is a shortcut for manually running the following generators:
FAQs
Boilerplate generator framework & low-code power tool 🛠️
The npm package boiler-dev receives a total of 1 weekly downloads. As such, boiler-dev popularity was classified as not popular.
We found that boiler-dev demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
Product
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.
Research
Security News
Socket researchers have discovered multiple malicious npm packages targeting Solana private keys, abusing Gmail to exfiltrate the data and drain Solana wallets.