burnjs
![](https://github.com/floveluy/Burnjs/blob/master/burnlogo.png) # Burnjs burnjs是系列教程[《使用Typescript封装一款装饰器风格的Web框架》](https://www.gitbook.com/book/215566435/-typescript-web/details)配套框架,全部使用Typescript编写完成。
Last updated 2 years ago by snakegear .
MIT · Original npm · Tarball · package.json
$ cnpm install burnjs 
SYNC missed versions from official npm registry.

Burnjs

burnjs是系列教程《使用Typescript封装一款装饰器风格的Web框架》配套框架,全部使用Typescript编写完成。

快速开始

#安装脚手架
npm install -g burn-cli
#初始化项目
burn-cli -init-ts myapp
#进入目录
cd myapp
#安装依赖
npm install

项目结构介绍

通过我写的小工具,生成的项目目录如下

.
├── README.md  #readme文件
├── app         #app文件夹,我们的TS编译出来的就是这样的
├── nodemon.json  #nodemon的配置文件
├── package-lock.json
├── package.json  #npm包文件
├── src   #TS,工作目录
│   ├── config  #配置文件目录
│   │   ├── config.default.ts  #普通配置
│   │   ├── config.dev.ts  #开发环境配置
│   │   ├── plugin.ts  #插件配置
│   ├── controller   #控制器目录
│   │   └── index.ts   #
│   ├── service     #业务逻辑目录
│   │   └── svs.ts
│   └── start.ts   #app启动入口
└── tsconfig.json  #TS编译配置文件

快速编写一个路由

//index.ts
import { Controller, Blueprint } from 'burnjs';

export default class Index extends Controller {
    @Blueprint.get('/')
    async first() {
        this.ctx.body = 'hello burn.js'
    }
}

启动调试

#启动项目
npm run dev

测试

npm run test

Current Tags

  • 1.0.17                                ...           latest (2 years ago)

37 Versions

  • 1.0.17                                ...           2 years ago
  • 1.0.16                                ...           2 years ago
  • 1.0.15                                ...           2 years ago
  • 1.0.14                                ...           2 years ago
  • 1.0.13                                ...           2 years ago
  • 1.0.12                                ...           2 years ago
  • 1.0.11                                ...           2 years ago
  • 1.0.10                                ...           2 years ago
  • 1.0.9                                ...           2 years ago
  • 1.0.8                                ...           2 years ago
  • 1.0.7                                ...           2 years ago
  • 1.0.6                                ...           2 years ago
  • 1.0.5                                ...           2 years ago
  • 1.0.4                                ...           2 years ago
  • 1.0.3                                ...           2 years ago
  • 1.0.2                                ...           2 years ago
  • 1.0.1                                ...           2 years ago
  • 1.0.0                                ...           2 years ago
  • 0.0.22                                ...           2 years ago
  • 0.0.21                                ...           2 years ago
  • 0.0.20                                ...           2 years ago
  • 0.0.16                                ...           2 years ago
  • 0.0.15                                ...           2 years ago
  • 0.0.14                                ...           2 years ago
  • 0.0.13                                ...           2 years ago
  • 0.0.12                                ...           2 years ago
  • 0.0.11                                ...           2 years ago
  • 0.0.10                                ...           2 years ago
  • 0.0.9                                ...           2 years ago
  • 0.0.8                                ...           2 years ago
  • 0.0.7                                ...           2 years ago
  • 0.0.6                                ...           2 years ago
  • 0.0.5                                ...           2 years ago
  • 0.0.4                                ...           2 years ago
  • 0.0.3                                ...           2 years ago
  • 0.0.2                                ...           2 years ago
  • 0.0.1                                ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 1
Dependencies (15)
Dev Dependencies (0)
None
Dependents (1)

Copyright 2014 - 2016 © taobao.org |