New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@backstage/plugin-app-backend

Package Overview
Dependencies
Maintainers
3
Versions
1306
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@backstage/plugin-app-backend

A Backstage backend plugin that serves the Backstage frontend app

  • 0.4.5
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
44K
decreased by-7.03%
Maintainers
3
Weekly downloads
 
Created
Source

App backend plugin

This backend plugin can be installed to serve static content of a Backstage app.

Installation

Add both this package and your local frontend app package as dependencies to your backend, for example

# From your Backstage root directory
yarn --cwd packages/backend add @backstage/plugin-app-backend app

By adding the app package as a dependency we ensure that it is built as part of the backend, and that it can be resolved at runtime.

Now add the plugin to your app, creating it for example like this:

New Backend

import { createBackend } from '@backstage/backend-defaults';

const backend = createBackend();
backend.add(import('@backstage/plugin-app-backend'));
backend.start();

Old Backend

const router = await createRouter({
  logger: env.logger,
  appPackageName: 'example-app',
});

And registering it like this:

createServiceBuilder(module)
  ...
  .addRouter('', router);

Be sure to register the app router last, as it serves content for HTML5-mode navigation, i.e. falling back to serving index.html for any route that can't be found.

Keywords

FAQs

Package last updated on 18 Feb 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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc