Coder Social home page Coder Social logo

taliove / typescript-webpack-init Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 1.0 32 KB

使用typescript+webpack建立前端项目集。以生成不同的具有复用性的单页应用。

License: GNU General Public License v2.0

JavaScript 95.62% HTML 2.77% CSS 0.34% TypeScript 1.26%
typescript-webpack webpack ts typescript vue2

typescript-webpack-init's Introduction

typescript-webpack-init

使用typescript+webpack初始化项目集。以创建SPA(单页应用)项目。

使用说明

  1. 克隆仓库
  2. 在根目录下执行npm intsall
  3. 在目录src/projects中新增项目名称,例如test,在其目录下创建入口文件:index.tsindex.html即可
  4. 在各自项目目录下,可设置项目资源文件夹static,该文件夹在生成项目时,直接拷贝至项目生成根目录

命令

执行npm run build可进行全部项目(projects目录)生成。

执行npm run build project-name可进行指定项目生成。

执行npm run dev project-name可进行指定项目的热加载开发。

项目配置

在项目文件夹下创建文件config.json可用于配置生成。

属性名称 类型 默认值 说明
js-name string [name].[chunkhash:8].js 输出js名称
css-name string [name].[contenthash:8].css 输出css名称
port int 9001 dev端口号

生成目录

所有项目都生成在目录./dist/下。

目录src/common/static下的文件均会生成至./dist/static下。

感谢

License

MIT

TALIOVE.COM © 2018~2019

typescript-webpack-init's People

Contributors

taliove avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

jixoba

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.