stream
요청 라우팅, 필터링, 템플릿 엔진, MVC 설계 패턴 및 파일 기반 정적 리소스를 지원하는 가벼운 Dart 웹 서버입니다.
경량 Dart 웹 서버. 기능: 요청 라우팅, 필터링, 템플릿 엔진, WebSocket, MVC 설계 패턴 및 파일 기반 정적 리소스.
아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.
Stream is a Dart web server supporting request routing, filtering, template engine, WebSocket, MVC design pattern and file-based static resources.
Add this to your pubspec.yaml (or create it):
dependencies:
stream:
There are two ways to compile RSP files into dart files: automatic building with Dart Editor or manual compiling.
RSP is a template technology allowing developers to create dynamically generated web pages based on HTML, XML or other document types (such as this and this).
To compile your RSP files automatically, you just need to add a build.dart file in the root directory of your project, with the following content:
import 'package:stream/rspc.dart';
void main(List<String> arguments) {
build(arguments);
}
With this build.dart script, whenever your RSP is modified, it will be re-compiled.
To compile a RSP file manually, run rspc (RSP compiler) to compile it into the dart file with command line interface as follows:
dart -c lib/rspc.dart -n dir1 dir2 file1 fire2...
A dart file is generated for each RSP file you gave. Fore more options, please run:
dart -c lib/rspc.dart -h
If you'd like to contribute back to the core, you can fork this repository and send us a pull request, when it is ready.
Please be aware that one of Stream's design goals is to keep the sphere of API as neat and consistency as possible. Strong enhancement always demands greater consensus.
If you are new to Git or GitHub, please read this guide first.