architect / plugin-remix

Architect plugin for Remix.
https://www.npmjs.com/package/@architect/plugin-remix
Apache License 2.0
13 stars 1 forks source link
architect remix-run serverless
Architect logo light Architect logo

@architect/plugin-remix

Mix Remix into an Architect project.

GitHub CI status

Install

⚠️ This plugin is still pre-v1. Give it a go and provide any feedback by filing an issue.

Into your existing Architect project:

npm i @architect/plugin-remix --save-dev

Add the following to your Architect project manifest (usually app.arc):

@plugins
architect/plugin-remix

@remix

Create a remix.config.js in your Architect project root:

// ./remix.config.js

module.exports = {}

Requirements

Architect 10+

Examples

See examples/ for sample apps.

How it works

@architect/plugin-remix is an Architect (v10+) plugin that automatically integrates the Remix framework into an Arc project.

To achieve this, the plugin hooks into Architect's local development Sandbox and deployment commands in order to build and serve a Remix project (from ./app by default).

This plugin automatically configures and uses Remix's built-in watcher as a sub-process of Architect's Sandbox.

The following directories are automatically managed (see configuration for options):

Configuration

Available plugin options and their defaults:

@remix
app-directory app
build-directory .remix

Interaction with remix.config.js

@architect/plugin-remix makes its best effort to respect a project's existing remix.config.js, but does control Remix build directories to better integrate with Architect.

Based on plugin defaults and plugin configuration (via @remix in app.arc), the following options are mutated before being passed to Remix:

appDirectory
assetsBuildDirectory
cacheDirectory
publicPath
serverBuildPath

Known Issues