New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@mdxe/deploy

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mdxe/deploy

Unified deployment interface for MDX projects - deploy to .do, Cloudflare, Vercel, or GitHub Pages

latest
Source
npmnpm
Version
1.9.0
Version published
Maintainers
1
Created
Source

@mdxe/deploy

Unified deployment interface for MDX projects. Deploy to .do, Cloudflare, Vercel, or GitHub Pages with a single API.

Installation

pnpm add @mdxe/deploy

Usage

Auto-detect platform

import { deploy } from '@mdxe/deploy'

// Detects platform from wrangler.toml, vercel.json, or defaults to .do
const result = await deploy({
  projectDir: './my-project',
  name: 'my-site',
})

console.log(`Deployed to ${result.platform}: ${result.url}`)

Deploy to specific platform

// Deploy to .do platform (default)
await deploy({
  projectDir: './my-project',
  platform: 'do',
})

// Deploy to Cloudflare
await deploy({
  projectDir: './my-project',
  platform: 'cloudflare',
})

// Deploy to Vercel
await deploy({
  projectDir: './my-project',
  platform: 'vercel',
  production: true,
})

// Deploy to GitHub Pages
await deploy({
  projectDir: './my-project',
  platform: 'github',
  repository: 'user/repo',
})

Platform Detection

The package automatically detects the best platform based on:

  • Explicit config - wrangler.toml → Cloudflare, vercel.json → Vercel
  • Default - .do platform (managed serverless)
import { detectPlatform } from '@mdxe/deploy'

const detection = detectPlatform('./my-project')
console.log(detection)
// { platform: 'do', confidence: 0.9, framework: 'nextjs', isStatic: false }

Platform-Specific Helpers

import { deployToDo, deployToCloudflare, deployToVercel, deployToGitHub } from '@mdxe/deploy'

await deployToDo({ projectDir: '.' })
await deployToCloudflare({ projectDir: '.' })
await deployToVercel({ projectDir: '.' })
await deployToGitHub({ projectDir: '.' })

Deployment Management

import { getDeploymentStatus, cancelDeployment, deleteDeployment } from '@mdxe/deploy'

// Check status (Vercel)
const status = await getDeploymentStatus('vercel', 'deployment-id')

// Cancel deployment
await cancelDeployment('vercel', 'deployment-id')

// Delete deployment
await deleteDeployment('vercel', 'deployment-id')

Custom Providers

import { registerProvider, type DeployProvider } from '@mdxe/deploy'

const customProvider: DeployProvider = {
  platform: 'custom',
  name: 'Custom Platform',
  async deploy(options) {
    // Your deployment logic
    return { success: true, url: 'https://...' }
  },
  supports(options) {
    return true
  },
}

registerProvider(customProvider)

Keywords

mdxe

FAQs

Package last updated on 20 Dec 2025

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