frontend starter
v1
プロジェクトテンプレートは、静的サイトを速く構築する方法です。 1つのコマンドを使用して、Webpack、Gulp、HandleBars.js、およびSCSSを使用して静的ページを構築します。
[ES6]
端末から1つのコマンドがあるすべてのコマンド:
yarn start
npm install -g gulp # May require `sudo`
yarn install # One time
gulp serve
次のプロジェクトにこのリポジトリを使用する場合は、次の変更を行ってください。
data.yml
を編集し、サイトに関連付けられているHTMLメタデータに記入します。package.json
、 name
、 version
、 description
、 license
、およびrepository.url
提供します。.git
フォルダーを削除して、新しいコミット履歴から開始します。README.md
好みに編集します。 利用可能なガルプコマンドの概要:
gulp build
サイトをdist
ディレクトリに構築します。これには次のものが含まれます。
gulp build:optimized
これは、最適化されたバージョンのサイト(展開用)の配布に使用されます。 gulp build
と次のすべてが含まれています。
gulp watch
ローカルファイルの変更を監視し、必要に応じてサイトの一部をdist
ディレクトリに再構築します。
gulp serve
バックグラウンドでgulp watch
実行し、Browsersyncを使用した自動リロードでlocalhost:3000
のdist
Directoryを提供します。
├── webpack.config.dev.js # Controls javascript and css bundling
├── Gulpfile.js # Controls Gulp, used for building the website
├── README.md # This file
├── data.yml # Metadata associated with the site.
├── dist/ # Gulp builds the static site into this directory
├── package.json # Dependencies
└── src/ # All source code
├── assets/
├── css/ # Stylesheets
├── font/ # Font files
├── img/ # Images and SVGs
├── js/ # Javascript libraries and scripts
├── views/
├── partials/ # Handlebars HTML partials that are included / extended
└── templates/ # Handlebars HTML files, one per page on the site.