@webruntime/framework-server
Not all projects are equal and definitely not all projects are [turn-key](https://git.soma.salesforce.com/communities/create-talon-app). If you would like to run Lightning Web Runtime without the CLI, we expose some of our programmatic APIs available in N
Last updated 5 months ago by tconn .
MIT · Original npm · Tarball · package.json
$ cnpm install @webruntime/framework-server 
SYNC missed versions from official npm registry.

Lightning Web Runtime :: Core API

Not all projects are equal and definitely not all projects are turn-key. If you would like to run Lightning Web Runtime without the CLI, we expose some of our programmatic APIs available in Node.js. If you're looking for the CLI documentation you can find that here.

Context

Most operations require that a context be already established. The context says a lot about your application and since the compiler is stateless, you will have to establish a context before starting. The context-service provides you with 3 methods: startContext, getContext and endContext.

Usage

import { startContext } from '@webruntime/api';

await contextService.startContext(options);

try {
    // do something
} finally {
    contextService.endContext();
}

Reference

Context Service Documentation

Generators

TBD

Usage

Get all the resources for the current application:

import { routeService, resourceService } from '@webruntime/api';

const resources = routeService.getRoutesResources(routes, theme, locale, isDesignMode);
await Promise.all(
    resources.map(routeDescriptor => {
        return resourceService.get(routeDescriptor);
    })
);

Reference

Express Middlewares

TBD

Reference

Current Tags

  • 0.18.49                                ...           latest (5 months ago)

5 Versions

  • 0.18.49                                ...           5 months ago
  • 0.18.47                                ...           5 months ago
  • 0.18.46                                ...           5 months ago
  • 0.18.45                                ...           5 months ago
  • 0.18.39                                ...           5 months ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (40)
Dependents (1)

Copyright 2014 - 2016 © taobao.org |