flixel |アドオン| ui |デモ|ツール|テンプレート|ドキュメント| haxeflixel.com
これがhaxeflixel.comのソースです。静的サイト生成には110、スタイリングにはブートストラップ5を使用します。
サイトをコンパイルするにはnpm / nodejsが必要です。プルリクエストは大歓迎です。
nodejsをインストールします
クローンとサイトを実行します
git clone https://github.com/HaxeFlixel/haxeflixel.com.git
cd haxeflixel.com依存関係をインストールしてサイトを構築するには、次のコマンドを実行します。
# downloads dependencies, and clones flixel-docs
npm install
# runs the start command from package.json, which boots up the static site generator and scss styling for live reload
npm run starthttp:// localhost:8080/を開く
content/ 、 content/_layouts/ 、およびcontent/_scss/ディレクトリを変更して、ハッキングを開始します。変更するファイルを保存すると、サイトはリロードされます。
開発情報については、貢献コードを参照してください。
当社のウェブサイトに貢献して改善したい場合は、フォークまたは機能ブランチで作業してください。作業およびテストされた変更のみがマスターに統合されます。開発者のサポートと変更に関する承認のために問題システムを使用してください。
Flixel-Docsリポジトリから自動的にプルされた/documentationのドキュメント(Scripts /Install-Flixel-Docs-Repo.jsを実行するPackage.json preinstallスクリプトを介して)。
haxeflixel.com/documentationページの更新に関する詳細については、Flixel-DocsリポジトリのReadMeを確認してください。
この例に従って、 /content/demosで.mdファイルを作成します。
```
---
title: "Demo-Name"
layout: demo
width: 800
height: 500
source: "flixel-demos-subdirectory/Demo-Name"
---
Here goes the actual description of the demo in GitHub-Flavored-Markdown:
* What the demo displays
* Who created it
* What the controls are
* etc
HTML is still allowed and can be used for more advanced descriptions.
```
source 、デモを含むFlixel-Demosのサブディレクトリを指します。
widthとheightデフォルトでは640および480で、その場合は省略する必要があります。
/static/demos/imagesにDemo-Name.pngという名前のデモのスクリーンショットを追加します。/content/showcaseで.mdファイルを作成します。 ---
layout: showcase
title: "Go! Go! PogoGirl"
itch: https://ohsat-andrej.itch.io/go-go-pogogirl
website: https://www.ohsat.com/game/go-go-pogogirl/
steam: https://store.steampowered.com/app/1681010/Go_Go_PogoGirl/
switch: https://www.nintendo.com/store/products/go-go-pogogirl-switch/
ps4: https://store.playstation.com/en-us/product/UP0891-PPSA10169_00-GOGOPOGOGIRLRATG
xbox: https://www.microsoft.com/store/productid/9P10H7L6QCCJ
date: "2022-02-01"
---
Dates should use YYYY-MM-DD
Note that by adding a URL to one of the supported targets, the icon will automatically become coloured on the
[showcase page](https://haxeflixel.com/showcase) and link to that URL.
*.mdファイルで使用されているのと同じタイトルを使用して、ショーケースのスクリーンショットを追加しますGo! Go! PogoGirl.png to /static/images/showcase 。それらはサイズ変更され、500x260にトリミングされるため、同じ比率を使用するのが最善です。まだ公式にリリースされていないショーケースは、特別なケースでのみ受け入れられています。ゲームジャムのゲームにも同じことが言えます。
コマンドを正常にインストールして実行することに加えて(ほぼ参照)、他の有用なコマンド /ワークフローがあります。
必要なものはすべて、 npm installでインストールする必要があります。 VSCODEを使用すると、自動フォーマットに推奨される拡張機能をインストールすることもできます(ファイル保存)。ただし、すべてのワークフローはCLIを介して完全に使用できる必要があります。
content/_staticすべての静的ファイル(通常 /ほとんど /ほとんど画像)は、ディレクトリ情報がタクストに保たれている状態で、サイトのルートディレクトリにコピーされます。したがって、 content/_static/images/ out/imagesに変わり、単なる/images/でサイトから参照する必要があります。
npm run start npm run startを実行すると、110のサイトとSASS .SCSSが起動し、変更にリロードします。
npm test npm testを実行すると、プロジェクトのフォーマットテストと糸くずが実行されます。すべてのテストを実行する場合は、単にnpm testを実行できます( test:js 、 test:liquid 、 test:prettier )。
ただし、各テストを個別に実行することもできます。
npm run test:js標準を介してJavaScriptをテストします。すべてを自動的に修正するには、 npm run npm run fix:js`を実行できます
npm run test:liquid 、サイトがeleventy --dryrunを介して構築されているかどうかをテストします。
npm run test:prettier Prettierを使用して一般的なスタイリングの一貫性をテストします。 npm run fix:prettier 。
npm fix npm fix実行すると、コードがstandardjs 、 .liquidrc 、および.prettierrc.yamlと一致するように自動フォーマットを行います。通常、PRを提出する前に実行したいと思うでしょう!