Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@freestyle-sh/with-dev-server

Package Overview
Dependencies
Maintainers
2
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@freestyle-sh/with-dev-server

Node.js runtime via [NVM](https://github.com/nvm-sh/nvm) for [Freestyle](https://freestyle.sh) VMs.

latest
npmnpm
Version
0.1.11
Version published
Maintainers
2
Created
Source

@freestyle-sh/with-nodejs

Node.js runtime via NVM for Freestyle VMs.

Installation

npm install @freestyle-sh/with-nodejs freestyle

Usage

import { freestyle, VmSpec } from "freestyle";
import { VmDevServer } from "../src/index";
import { VmPtySession } from "@freestyle-sh/with-pty";

const TEMPLATE_REPO = "https://github.com/freestyle-sh/freestyle-next";

const { repoId } = await freestyle.git.repos.create({
  source: {
    url: TEMPLATE_REPO,
  },
});

const domain = `${repoId}.style.dev`;
const devPty = new VmPtySession({ sessionId: "dev-server" });

const { vm } = await freestyle.vms.create({
  snapshot: new VmSpec({
    with: {
      devPty,
      devServer: new VmDevServer({
        workdir: "/repo",
        templateRepo: TEMPLATE_REPO,
        devCommand: "npm run dev",
        devCommandPty: devPty,
      }),
    },
  }),
  with: {
    devServer: new VmDevServer({
      repo: repoId,
    }),
  },
  domains: [
    {
      domain: domain,
      vmPort: 3000,
    },
  ],
});

FAQs

Package last updated on 21 Apr 2026

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