mirror of
https://github.com/LukeHagar/vercel.git
synced 2025-12-12 12:57:47 +00:00
Compare commits
180 Commits
@now/pytho
...
@now/pytho
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5c71f672b3 | ||
|
|
dbc5f73984 | ||
|
|
1d269fffc8 | ||
|
|
cc146ba0f5 | ||
|
|
f8a2519838 | ||
|
|
1781376d47 | ||
|
|
d9fda14969 | ||
|
|
a4de9272e7 | ||
|
|
9b9037de91 | ||
|
|
8d18c65e3e | ||
|
|
e7d7de61b6 | ||
|
|
11927883c3 | ||
|
|
57d25b184b | ||
|
|
95f716fb3f | ||
|
|
8dd52605be | ||
|
|
4b9c6a2a2a | ||
|
|
17f92a5ad3 | ||
|
|
0aab7cc509 | ||
|
|
b39622b271 | ||
|
|
1e9aeee8e9 | ||
|
|
49fac0dfad | ||
|
|
a668df829f | ||
|
|
3d4ef1f825 | ||
|
|
f986daa1cc | ||
|
|
549c8777ba | ||
|
|
51d7242fda | ||
|
|
36db0e5bab | ||
|
|
99368b4248 | ||
|
|
95daf0e292 | ||
|
|
8bfa9c1a42 | ||
|
|
4208dc0466 | ||
|
|
00ae011b95 | ||
|
|
a770991a81 | ||
|
|
f80a6d6392 | ||
|
|
30777384ec | ||
|
|
0c719b7f6a | ||
|
|
ff18788b20 | ||
|
|
752ab39787 | ||
|
|
c1df8c8bd1 | ||
|
|
25fd1df35d | ||
|
|
d32ab1e0d9 | ||
|
|
a69c460760 | ||
|
|
b985853f15 | ||
|
|
94e607a93a | ||
|
|
f97a81fa14 | ||
|
|
6e28438eb4 | ||
|
|
8fcdf3f458 | ||
|
|
dbf0cc3562 | ||
|
|
27ccfa7e7a | ||
|
|
f37edbc670 | ||
|
|
b7943e83d2 | ||
|
|
300ed5b952 | ||
|
|
9e6ebfb3ec | ||
|
|
f49620790c | ||
|
|
84065688b5 | ||
|
|
5a1012fb0f | ||
|
|
4b6143c293 | ||
|
|
b6601b0d9a | ||
|
|
2870a1dd49 | ||
|
|
6249f7e293 | ||
|
|
6f9545e097 | ||
|
|
8095ba5cf9 | ||
|
|
e02128e5a3 | ||
|
|
2567b8c8b8 | ||
|
|
5bfcdec471 | ||
|
|
6609686a2b | ||
|
|
709aaf2285 | ||
|
|
6b3908d4dc | ||
|
|
9d19d02a0a | ||
|
|
533b059947 | ||
|
|
2a7c1dc4e4 | ||
|
|
07a920ed18 | ||
|
|
db36c874a0 | ||
|
|
cc58af74d6 | ||
|
|
1bcb95a9f0 | ||
|
|
e6a0216faf | ||
|
|
283ef46ac5 | ||
|
|
b4b1857562 | ||
|
|
c46c56bbf9 | ||
|
|
62ce2f6cac | ||
|
|
631c7befad | ||
|
|
bc18c34d60 | ||
|
|
6b6a1891c1 | ||
|
|
8879b115ef | ||
|
|
99c4c32d6d | ||
|
|
857da7774b | ||
|
|
3407e6bd1a | ||
|
|
553ad240f0 | ||
|
|
964ce1bb5a | ||
|
|
995aa6eddf | ||
|
|
095805e3ad | ||
|
|
b461ed238c | ||
|
|
01e7124189 | ||
|
|
acd3ac2f98 | ||
|
|
b50e4209e1 | ||
|
|
147b4e870c | ||
|
|
df8327d14c | ||
|
|
fb4d4b5953 | ||
|
|
de3701c045 | ||
|
|
9f9b7934cb | ||
|
|
bcded1dd17 | ||
|
|
8503af75ba | ||
|
|
158a50f1aa | ||
|
|
61da552dd6 | ||
|
|
fa838eecac | ||
|
|
71b6a58783 | ||
|
|
22dd78e286 | ||
|
|
e63fcf2630 | ||
|
|
98e1553c2e | ||
|
|
4dc506f17a | ||
|
|
3b396f29e9 | ||
|
|
1f128e69e6 | ||
|
|
f1487c92cb | ||
|
|
45066cdf44 | ||
|
|
7dde9c8207 | ||
|
|
fd964f825d | ||
|
|
1656c9874e | ||
|
|
d999a3b2ad | ||
|
|
cfb7c9e632 | ||
|
|
06e8472cf7 | ||
|
|
92404135d8 | ||
|
|
8b5cc23d7c | ||
|
|
e10b42bfdc | ||
|
|
36f7ec4836 | ||
|
|
f89d1c463e | ||
|
|
5dc652eba9 | ||
|
|
821b2bd50b | ||
|
|
8d5f6f1fa3 | ||
|
|
617f610c07 | ||
|
|
3229ba0106 | ||
|
|
d16a6e4716 | ||
|
|
4e5156fb0b | ||
|
|
3c013cc36b | ||
|
|
1ed83135be | ||
|
|
0e71ff2df1 | ||
|
|
d8e98ee476 | ||
|
|
1bc1e8a9b1 | ||
|
|
274fdeb49a | ||
|
|
d15c90b42f | ||
|
|
5be2917c47 | ||
|
|
5f08b24546 | ||
|
|
cc3026ffcb | ||
|
|
8cb6e56679 | ||
|
|
7da5ff4b1d | ||
|
|
5d1069d464 | ||
|
|
6e1a72f557 | ||
|
|
6f97a2cc7a | ||
|
|
6e402bffc3 | ||
|
|
e41d0f8e68 | ||
|
|
1a046744f2 | ||
|
|
a9bf011f2c | ||
|
|
60c76b3290 | ||
|
|
c7ff1e7044 | ||
|
|
e2deaef54a | ||
|
|
b2c7386c83 | ||
|
|
3dce84c3cf | ||
|
|
443b1ac158 | ||
|
|
be3dca3d94 | ||
|
|
cb135e4329 | ||
|
|
55c73b68bb | ||
|
|
eb793ba139 | ||
|
|
00908e8ebe | ||
|
|
5ce7ff86a4 | ||
|
|
4b34ee2993 | ||
|
|
646bd288ba | ||
|
|
8aba6f1ff8 | ||
|
|
35e5e328aa | ||
|
|
bdd4953d62 | ||
|
|
e938b298e2 | ||
|
|
b67f324e10 | ||
|
|
1dfa286af5 | ||
|
|
d4391bd4cc | ||
|
|
53eb71f26d | ||
|
|
92ffd654b5 | ||
|
|
36b83f1606 | ||
|
|
7a79f620c0 | ||
|
|
f3b286ecf3 | ||
|
|
adf31c3fcc | ||
|
|
deacdfc47c | ||
|
|
ac9badbe9e |
4
.gitattributes
vendored
4
.gitattributes
vendored
@@ -1,3 +1,7 @@
|
|||||||
# Ignore test fixtures in GitHub Languages
|
# Ignore test fixtures in GitHub Languages
|
||||||
# See https://github.com/github/linguist#vendored-code
|
# See https://github.com/github/linguist#vendored-code
|
||||||
packages/*/test/* linguist-vendored
|
packages/*/test/* linguist-vendored
|
||||||
|
|
||||||
|
# Go build fails with Windows line endings.
|
||||||
|
*.go text eol=lf
|
||||||
|
go.mod text eol=lf
|
||||||
|
|||||||
16
.github/CONTRIBUTING.md
vendored
16
.github/CONTRIBUTING.md
vendored
@@ -1,6 +1,6 @@
|
|||||||
# Contributing
|
# Contributing
|
||||||
|
|
||||||
When contributing to this repository, please first discuss the change you wish to make via [GitHub Issue](https://github.com/zeit/now/issues/new) or [Spectrum](https://spectrum.chat/zeit) with the owners of this repository before submitting a Pull Request.
|
When contributing to this repository, please first discuss the change you wish to make via [GitHub Discussions](https://github.com/zeit/now/discussions/new) with the owners of this repository before submitting a Pull Request.
|
||||||
|
|
||||||
Please read our [code of conduct](CODE_OF_CONDUCT.md) and follow it in all your interactions with the project.
|
Please read our [code of conduct](CODE_OF_CONDUCT.md) and follow it in all your interactions with the project.
|
||||||
|
|
||||||
@@ -97,13 +97,9 @@ Sometimes you want to test changes to a Builder against an existing project, may
|
|||||||
|
|
||||||
## Add a New Framework
|
## Add a New Framework
|
||||||
|
|
||||||
You can add support for a new framework by creating a Pull Request for this repository by following the steps below.
|
You can add support for a new Framework by creating a Pull Request for this repository and following the steps below:
|
||||||
|
|
||||||
1. Add the framework to the `@now/frameworks` package.
|
1. Add the Framework to the `@now/frameworks` package: The file is located in `packages/frameworks/frameworks.json`. You can copy the structure of an existing one and adjust the required fields. Note that the `settings` property either contains a `value` or a `placeholder`. The `value` property is used when something is not configurable, the `placeholder` is used when something is configurable and can be changed with configuration. An example would be the Output Directory for Hugo, it's `public` by default but can be changed through its config file, so we use `placeholder` with an explanation of what can be used.
|
||||||
The file is located in `packages/frameworks/frameworks.json`. You can copy the structure of an existing one and adjust the required fields. Note that the `settings` property either contains a `value` or a `placeholder`. The `value` property is used when something is not configurable, the `placeholder` is used when something is configurable and can be changed with configuration. An example would be the output directory for Hugo, it's `public` by default but can be changed through its config file, so we use `placeholder` with an explanation of what can be used.
|
2. Add an example to the `examples/` directory: The name of the directory should equal the slug of the framework used in `@now/frameworks`. The `.github/EXAMPLE_README_TEMPLATE.md` file can be used to create a `README.md` file for the example.
|
||||||
2. Add an example to the `examples/` directory.
|
3. Update the `@now/static-build` package: The file `packages/now-static-build/src/frameworks.ts` has to be extended. You can add default routes that will always be applied to projects that use this Framework or specify some paths that will be cached to speed up the build process.
|
||||||
The name of the directory should equal the slug of the framework used in `@now/frameworks`.
|
4. After your Pull Request has been merged and released, other users can select the example on the ZEIT Now dashboard and deploy it.
|
||||||
The `.github/EXAMPLE_README_TEMPLATE.md` file can be used to create a README for the example.
|
|
||||||
3. Update the `@now/static-build` package
|
|
||||||
The files `packages/now-static-build/src/frameworks.ts` has to be extended. You can add default routes that will always be applied to projects that use this framework or specify some paths that will be cached to speed up the build process.
|
|
||||||
4. After your PR has been merged and released other users can use `now init` to get the example and deploy it to ZEIT Now.
|
|
||||||
|
|||||||
2
.github/EXAMPLE_README_TEMPLATE.md
vendored
2
.github/EXAMPLE_README_TEMPLATE.md
vendored
@@ -6,7 +6,7 @@ This directory is a brief example of a [Name](site-link) site that can be deploy
|
|||||||
|
|
||||||
Deploy your own [Name] project with ZEIT Now.
|
Deploy your own [Name] project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now-examples/tree/master/example-directory)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now-examples/tree/master/example-directory)
|
||||||
|
|
||||||
### How We Created This Example
|
### How We Created This Example
|
||||||
|
|
||||||
|
|||||||
11
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
11
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
blank_issues_enabled: false
|
||||||
|
contact_links:
|
||||||
|
- name: Bug Report
|
||||||
|
url: https://zeit.co/support/request
|
||||||
|
about: Report a bug using the ZEIT Now support form
|
||||||
|
- name: Feature Request
|
||||||
|
url: https://github.com/zeit/now/discussions/new
|
||||||
|
about: Request a feature to be added to the platform
|
||||||
|
- name: Ask a Question
|
||||||
|
url: https://github.com/zeit/now/discussions/new
|
||||||
|
about: Ask questions and discuss with other community members
|
||||||
3
.github/workflows/cancel.yml
vendored
3
.github/workflows/cancel.yml
vendored
@@ -4,13 +4,14 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- '*'
|
- '*'
|
||||||
- '!master'
|
- '!master'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
cancel:
|
cancel:
|
||||||
name: 'Cancel Previous Runs'
|
name: 'Cancel Previous Runs'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
timeout-minutes: 3
|
timeout-minutes: 3
|
||||||
steps:
|
steps:
|
||||||
- uses: styfle/cancel-workflow-action@master
|
- uses: styfle/cancel-workflow-action@0.2.0
|
||||||
with:
|
with:
|
||||||
workflow_id: 435869
|
workflow_id: 435869
|
||||||
access_token: ${{ secrets.GITHUB_WORKFLOW_TOKEN }}
|
access_token: ${{ secrets.GITHUB_WORKFLOW_TOKEN }}
|
||||||
|
|||||||
32
.github/workflows/continuous-integration.yml
vendored
32
.github/workflows/continuous-integration.yml
vendored
@@ -15,7 +15,7 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
os: [ubuntu-latest, macos-latest]
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
||||||
node: [10, 12]
|
node: [10, 12]
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
@@ -23,7 +23,8 @@ jobs:
|
|||||||
- run: git fetch origin master --depth=10
|
- run: git fetch origin master --depth=10
|
||||||
- run: git fetch origin ${{ github.ref }} --depth=10
|
- run: git fetch origin ${{ github.ref }} --depth=10
|
||||||
- uses: actions/setup-node@v1
|
- uses: actions/setup-node@v1
|
||||||
- run: yarn install && yarn run build
|
- run: yarn install
|
||||||
|
- run: yarn run build
|
||||||
- run: yarn run test-lint
|
- run: yarn run test-lint
|
||||||
- run: yarn run test-unit --clean false
|
- run: yarn run test-unit --clean false
|
||||||
- name: Upload Artifact
|
- name: Upload Artifact
|
||||||
@@ -41,8 +42,12 @@ jobs:
|
|||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- run: git fetch origin master --depth=10
|
- run: git fetch origin master --depth=10
|
||||||
- run: git fetch origin ${{ github.ref }} --depth=10
|
- run: git fetch origin ${{ github.ref }} --depth=10
|
||||||
- run: yarn install && yarn run build
|
- run: yarn install
|
||||||
|
- run: yarn run build
|
||||||
- run: yarn test-integration-once --clean false
|
- run: yarn test-integration-once --clean false
|
||||||
|
env:
|
||||||
|
ZEIT_TEAM_TOKEN: ${{ secrets.ZEIT_TEAM_TOKEN }}
|
||||||
|
ZEIT_REGISTRATION_URL: ${{ secrets.ZEIT_REGISTRATION_URL }}
|
||||||
|
|
||||||
test-now-cli:
|
test-now-cli:
|
||||||
name: Now CLI Tests
|
name: Now CLI Tests
|
||||||
@@ -57,12 +62,18 @@ jobs:
|
|||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- run: git fetch origin master --depth=10
|
- run: git fetch origin master --depth=10
|
||||||
- run: git fetch origin ${{ github.ref }} --depth=10
|
- run: git fetch origin ${{ github.ref }} --depth=10
|
||||||
- run: curl -L -O https://github.com/gohugoio/hugo/releases/download/v0.56.0/hugo_0.56.0_macOS-64bit.tar.gz && tar -xzf hugo_0.56.0_macOS-64bit.tar.gz && mv ./hugo packages/now-cli/test/dev/fixtures/08-hugo/
|
- name: Install Hugo
|
||||||
- run: yarn install && yarn run build
|
if: matrix.os == 'macos-latest'
|
||||||
|
run: curl -L -O https://github.com/gohugoio/hugo/releases/download/v0.56.0/hugo_0.56.0_macOS-64bit.tar.gz && tar -xzf hugo_0.56.0_macOS-64bit.tar.gz && mv ./hugo packages/now-cli/test/dev/fixtures/08-hugo/
|
||||||
|
- run: yarn install
|
||||||
|
- run: yarn run build
|
||||||
- uses: actions/setup-node@v1
|
- uses: actions/setup-node@v1
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node }}
|
node-version: ${{ matrix.node }}
|
||||||
- run: yarn test-integration --clean false
|
- run: yarn test-integration --clean false
|
||||||
|
env:
|
||||||
|
ZEIT_TEAM_TOKEN: ${{ secrets.ZEIT_TEAM_TOKEN }}
|
||||||
|
ZEIT_REGISTRATION_URL: ${{ secrets.ZEIT_REGISTRATION_URL }}
|
||||||
|
|
||||||
test-now-dev:
|
test-now-dev:
|
||||||
name: "`now dev` Tests"
|
name: "`now dev` Tests"
|
||||||
@@ -77,8 +88,11 @@ jobs:
|
|||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- run: git fetch origin master --depth=10
|
- run: git fetch origin master --depth=10
|
||||||
- run: git fetch origin ${{ github.ref }} --depth=10
|
- run: git fetch origin ${{ github.ref }} --depth=10
|
||||||
- run: curl -L -O https://github.com/gohugoio/hugo/releases/download/v0.56.0/hugo_0.56.0_macOS-64bit.tar.gz && tar -xzf hugo_0.56.0_macOS-64bit.tar.gz && mv ./hugo packages/now-cli/test/dev/fixtures/08-hugo/
|
- name: Install Hugo
|
||||||
- run: yarn install && yarn run build
|
if: matrix.os == 'macos-latest'
|
||||||
|
run: curl -L -O https://github.com/gohugoio/hugo/releases/download/v0.56.0/hugo_0.56.0_macOS-64bit.tar.gz && tar -xzf hugo_0.56.0_macOS-64bit.tar.gz && mv ./hugo packages/now-cli/test/dev/fixtures/08-hugo/
|
||||||
|
- run: yarn install
|
||||||
|
- run: yarn run build
|
||||||
- uses: actions/setup-node@v1
|
- uses: actions/setup-node@v1
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node }}
|
node-version: ${{ matrix.node }}
|
||||||
@@ -86,7 +100,7 @@ jobs:
|
|||||||
|
|
||||||
coverage:
|
coverage:
|
||||||
name: Coverage
|
name: Coverage
|
||||||
timeout-minutes: 10
|
timeout-minutes: 5
|
||||||
needs: [test-unit, test-now-cli, test-now-dev, test-integration]
|
needs: [test-unit, test-now-cli, test-now-dev, test-integration]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
@@ -99,3 +113,5 @@ jobs:
|
|||||||
path: packages/now-cli/.nyc_output
|
path: packages/now-cli/.nyc_output
|
||||||
- run: yarn install
|
- run: yarn install
|
||||||
- run: yarn workspace now run coverage
|
- run: yarn workspace now run coverage
|
||||||
|
env:
|
||||||
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||||
|
|||||||
5
.github/workflows/publish.yml
vendored
5
.github/workflows/publish.yml
vendored
@@ -20,7 +20,12 @@ jobs:
|
|||||||
run: yarn install --check-files --frozen-lockfile
|
run: yarn install --check-files --frozen-lockfile
|
||||||
- name: Build
|
- name: Build
|
||||||
run: yarn build
|
run: yarn build
|
||||||
|
env:
|
||||||
|
GA_TRACKING_ID: ${{ secrets.GA_TRACKING_ID }}
|
||||||
|
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
||||||
- name: Publish
|
- name: Publish
|
||||||
run: yarn publish-from-github
|
run: yarn publish-from-github
|
||||||
env:
|
env:
|
||||||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||||
|
GA_TRACKING_ID: ${{ secrets.GA_TRACKING_ID }}
|
||||||
|
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
||||||
|
|||||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -12,6 +12,7 @@ coverage
|
|||||||
packages/now-cli/.builders
|
packages/now-cli/.builders
|
||||||
packages/now-cli/assets
|
packages/now-cli/assets
|
||||||
packages/now-cli/src/util/dev/templates/*.ts
|
packages/now-cli/src/util/dev/templates/*.ts
|
||||||
|
packages/now-cli/src/util/constants.ts
|
||||||
packages/now-cli/test/**/yarn.lock
|
packages/now-cli/test/**/yarn.lock
|
||||||
!packages/now-cli/test/dev/**/yarn.lock
|
!packages/now-cli/test/dev/**/yarn.lock
|
||||||
packages/now-cli/test/**/node_modules
|
packages/now-cli/test/**/node_modules
|
||||||
|
|||||||
22
README.md
22
README.md
@@ -1,34 +1,22 @@
|
|||||||

|

|
||||||
|
|
||||||
[](https://github.com/zeit/now/actions?workflow=CI)
|
[](https://github.com/zeit/now/actions?workflow=CI)
|
||||||
[](https://spectrum.chat/zeit)
|
[](https://github.com/zeit/now/discussions)
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
To install the latest version of Now CLI, visit [zeit.co/download](https://zeit.co/download) or run this command:
|
Get started by [Importing a Git Project](https://zeit.co/import) and use `git push` to deploy. Alternatively, you can [install Now CLI](https://zeit.co/download).
|
||||||
|
|
||||||
```
|
|
||||||
npm i -g now
|
|
||||||
```
|
|
||||||
|
|
||||||
To quickly start a new project, run the following commands:
|
|
||||||
|
|
||||||
```
|
|
||||||
now init # Pick an example project to clone
|
|
||||||
cd <PROJECT> # Change directory to the newly created project
|
|
||||||
now # Deploy to the cloud
|
|
||||||
```
|
|
||||||
|
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
For details on how to use Now CLI, check out our [documentation](https://zeit.co/docs).
|
For details on how to use ZEIT Now, check out our [documentation](https://zeit.co/docs).
|
||||||
|
|
||||||
## Caught a Bug?
|
## Caught a Bug?
|
||||||
|
|
||||||
1. [Fork](https://help.github.com/articles/fork-a-repo/) this repository to your own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local device
|
1. [Fork](https://help.github.com/articles/fork-a-repo/) this repository to your own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local device
|
||||||
2. Install dependencies with `yarn install`
|
2. Install dependencies with `yarn install`
|
||||||
3. Compile the code: `yarn build`
|
3. Compile the code: `yarn build`
|
||||||
4. Link the package to the global module directory: `yarn link`
|
4. Link the package to the global module directory: `cd ./packages/now-cli && yarn link`
|
||||||
5. You can now start using `now` anywhere inside the command line
|
5. You can now start using `now` anywhere inside the command line
|
||||||
|
|
||||||
As always, you should use `yarn test-unit` to run the tests and see if your changes have broken anything.
|
As always, you should use `yarn test-unit` to run the tests and see if your changes have broken anything.
|
||||||
|
|||||||
@@ -2,17 +2,18 @@ import { NowRequest, NowResponse } from '@now/node';
|
|||||||
import { withApiHandler } from './_lib/util/with-api-handler';
|
import { withApiHandler } from './_lib/util/with-api-handler';
|
||||||
import frameworkList, { Framework } from '../packages/frameworks';
|
import frameworkList, { Framework } from '../packages/frameworks';
|
||||||
|
|
||||||
const frameworks: Framework[] = (frameworkList as Framework[]).map(
|
const frameworks = (frameworkList as Framework[]).map(frameworkItem => {
|
||||||
framework => {
|
const framework = {
|
||||||
delete framework.detectors;
|
...frameworkItem,
|
||||||
|
detectors: undefined,
|
||||||
|
};
|
||||||
|
|
||||||
if (framework.logo) {
|
if (framework.logo) {
|
||||||
framework.logo = `https://res.cloudinary.com/zeit-inc/image/fetch/${framework.logo}`;
|
framework.logo = `https://res.cloudinary.com/zeit-inc/image/fetch/${framework.logo}`;
|
||||||
}
|
|
||||||
|
|
||||||
return framework;
|
|
||||||
}
|
}
|
||||||
);
|
|
||||||
|
return framework;
|
||||||
|
});
|
||||||
|
|
||||||
export default withApiHandler(async function(
|
export default withApiHandler(async function(
|
||||||
req: NowRequest,
|
req: NowRequest,
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ Contributing to Now Examples should be an enjoyable experience, as such we have
|
|||||||
|
|
||||||
The guidelines cover important information such as the requirements for new examples and where to get help if you have any questions.
|
The guidelines cover important information such as the requirements for new examples and where to get help if you have any questions.
|
||||||
|
|
||||||
We have tried to make contributing to Now Examples as easy as possible, especially for those new to Open Source. If anything is unclear or you have any questions then please reach out to us on [ZEIT Spectrum](https://spectrum.chat/zeit) where we will do our best to help you.
|
We have tried to make contributing to Now Examples as easy as possible, especially for those new to Open Source. If anything is unclear or you have any questions then please reach out to us on [GitHub Discussions](https://github.com/zeit/now/discussions) where we will do our best to help you.
|
||||||
|
|
||||||
## Reporting Issues
|
## Reporting Issues
|
||||||
|
|
||||||
@@ -80,6 +80,6 @@ Now Examples is an open source project released under the [MIT License](https://
|
|||||||
|
|
||||||
## Get In Touch
|
## Get In Touch
|
||||||
|
|
||||||
If you have any questions that are not covered by raising an issue then please get in touch with us on the [ZEIT Spectrum](https://spectrum.chat/zeit). There you will find both members of the community and staff who are happy to help answer questions on anything ZEIT related.
|
If you have any questions that are not covered by raising an issue then please get in touch with us on [GitHub Discussions](https://github.com/zeit/now/discussions). There you will find both members of the community and staff who are happy to help answer questions on anything ZEIT related.
|
||||||
|
|
||||||
[](https://spectrum.chat/zeit)
|
[](https://github.com/zeit/now/discussions)
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ This directory is a brief example of an [AMP](https://amp.dev/) site that can be
|
|||||||
|
|
||||||
Deploy your own AMP project with ZEIT Now.
|
Deploy your own AMP project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/amp)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/amp)
|
||||||
|
|
||||||
_Live Example: https://amp.now-examples.now.sh_
|
_Live Example: https://amp.now-examples.now.sh_
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||

|

|
||||||
|
|
||||||
# Angular Example
|
# Angular Example
|
||||||
|
|
||||||
@@ -8,7 +8,7 @@ This directory is a brief example of an [Angular](https://angular.io/) app that
|
|||||||
|
|
||||||
Deploy your own Angular project with ZEIT Now.
|
Deploy your own Angular project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/angular)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/angular)
|
||||||
|
|
||||||
_Live Example: https://angular.now-examples.now.sh_
|
_Live Example: https://angular.now-examples.now.sh_
|
||||||
|
|
||||||
|
|||||||
14
examples/assemble/.gitattributes
vendored
14
examples/assemble/.gitattributes
vendored
@@ -1,14 +0,0 @@
|
|||||||
# Enforce Unix newlines
|
|
||||||
*.* text eol=lf
|
|
||||||
*.css text eol=lf
|
|
||||||
*.html text eol=lf
|
|
||||||
*.js text eol=lf
|
|
||||||
*.json text eol=lf
|
|
||||||
*.less text eol=lf
|
|
||||||
*.md text eol=lf
|
|
||||||
*.yml text eol=lf
|
|
||||||
|
|
||||||
*.jpg binary
|
|
||||||
*.gif binary
|
|
||||||
*.png binary
|
|
||||||
*.jpeg binary
|
|
||||||
47
examples/assemble/.gitignore
vendored
47
examples/assemble/.gitignore
vendored
@@ -1,47 +0,0 @@
|
|||||||
# Numerous always-ignore extensions
|
|
||||||
.ruby-version
|
|
||||||
*.diff
|
|
||||||
*.err
|
|
||||||
*.orig
|
|
||||||
*.log
|
|
||||||
*.rej
|
|
||||||
*.swo
|
|
||||||
*.swp
|
|
||||||
*.zip
|
|
||||||
*.vi
|
|
||||||
*~
|
|
||||||
|
|
||||||
# OS or Editor folders
|
|
||||||
*.esproj
|
|
||||||
*.sublime-project
|
|
||||||
*.sublime-workspace
|
|
||||||
._*
|
|
||||||
.cache
|
|
||||||
.DS_Store
|
|
||||||
.idea
|
|
||||||
.project
|
|
||||||
.settings
|
|
||||||
.tmproj
|
|
||||||
nbproject
|
|
||||||
Thumbs.db
|
|
||||||
|
|
||||||
# Komodo
|
|
||||||
*.komodoproject
|
|
||||||
.komodotools
|
|
||||||
|
|
||||||
# grunt-html-validation
|
|
||||||
validation-status.json
|
|
||||||
validation-report.json
|
|
||||||
|
|
||||||
# Folders to ignore
|
|
||||||
tmp
|
|
||||||
temp
|
|
||||||
TODO.md
|
|
||||||
vendor
|
|
||||||
node_modules
|
|
||||||
bower_components
|
|
||||||
_gh_pages
|
|
||||||
_site
|
|
||||||
_draft
|
|
||||||
.env
|
|
||||||
.env.build
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
README.md
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
/*
|
|
||||||
* assemble-examples <https://github.com/assemble/assemble-examples>
|
|
||||||
*
|
|
||||||
* Copyright (c) 2014 Jon Schlinkert, Brian Woodward, contributors.
|
|
||||||
* Licensed under the MIT license.
|
|
||||||
*/
|
|
||||||
|
|
||||||
module.exports = function(grunt) {
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
grunt.initConfig({
|
|
||||||
assemble: {
|
|
||||||
options: {
|
|
||||||
flatten: true,
|
|
||||||
partials: ['templates/includes/*.hbs'],
|
|
||||||
layoutdir: 'templates/layouts',
|
|
||||||
layout: 'default.hbs',
|
|
||||||
},
|
|
||||||
site: {
|
|
||||||
files: { 'public/index.js': ['templates/*.hbs'] },
|
|
||||||
},
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
// Load the Assemble plugin.
|
|
||||||
grunt.loadNpmTasks('assemble');
|
|
||||||
|
|
||||||
// The default task to run with the `grunt` command.
|
|
||||||
grunt.registerTask('default', ['assemble']);
|
|
||||||
};
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
# Assemble Example
|
|
||||||
|
|
||||||
This directory is a brief example of a [Assemble](http://assemble.io/) app that can be deployed with ZEIT Now and zero configuration.
|
|
||||||
|
|
||||||
## Deploy Your Own
|
|
||||||
|
|
||||||
Deploy your own Assemble project with ZEIT Now.
|
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/assemble)
|
|
||||||
|
|
||||||
_Live Example: https://assemble.now-examples.now.sh_
|
|
||||||
|
|
||||||
### How We Created This Example
|
|
||||||
|
|
||||||
To get started with Assemble deployed with ZEIT Now, you can use [Now CLI](https://zeit.co/download) to initialize the project:
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now init assemble
|
|
||||||
```
|
|
||||||
|
|
||||||
### Deploying From Your Terminal
|
|
||||||
|
|
||||||
You can deploy your new Assemble project with a single command from your terminal using [Now CLI](https://zeit.co/download):
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now
|
|
||||||
```
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
# Blog post
|
|
||||||
|
|
||||||
> This is an example blog post
|
|
||||||
|
|
||||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
|
|
||||||
|
|
||||||
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "assemble-example",
|
|
||||||
"private": true,
|
|
||||||
"description": "Example Assemble project.",
|
|
||||||
"version": "0.1.1",
|
|
||||||
"homepage": "https://github.com/jonschlinkert/assemble-example",
|
|
||||||
"scripts": {
|
|
||||||
"build": "grunt assemble"
|
|
||||||
},
|
|
||||||
"author": {
|
|
||||||
"name": "Jon Schlinkert",
|
|
||||||
"url": "https://github.com/jonschlinkert"
|
|
||||||
},
|
|
||||||
"repository": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://github.com/jonschlinkert/assemble-example.git"
|
|
||||||
},
|
|
||||||
"bugs": {
|
|
||||||
"url": "https://github.com/jonschlinkert/assemble-example/issues"
|
|
||||||
},
|
|
||||||
"licenses": [
|
|
||||||
{
|
|
||||||
"type": "MIT",
|
|
||||||
"url": "https://github.com/jonschlinkert/assemble-example/blob/master/LICENSE-MIT"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"main": "index.js",
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 0.8.0"
|
|
||||||
},
|
|
||||||
"dependencies": {},
|
|
||||||
"devDependencies": {
|
|
||||||
"assemble": "~0.4.37",
|
|
||||||
"grunt": "~0.4.3",
|
|
||||||
"grunt-cli": "^1.3.2"
|
|
||||||
},
|
|
||||||
"keywords": []
|
|
||||||
}
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
---
|
|
||||||
title: About
|
|
||||||
description: This is the about page.
|
|
||||||
---
|
|
||||||
<h2>{{description}}</h2>
|
|
||||||
|
|
||||||
{{> button }}
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
---
|
|
||||||
title: Blog
|
|
||||||
---
|
|
||||||
|
|
||||||
{{md 'content/blog-post.md'}}
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
---
|
|
||||||
title: Home
|
|
||||||
description: This is the home page.
|
|
||||||
---
|
|
||||||
<h2>{{description}}</h2>
|
|
||||||
|
|
||||||
{{> button }}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
<a href="https://github.com/assemble/assemble" class="btn btn-default">Star Assemble on GitHub!</a>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
<meta charset="UTF-8">
|
|
||||||
<title>{{title}}</title>
|
|
||||||
<link rel="stylesheet" href="http://getbootstrap.com/dist/css/bootstrap.min.css">
|
|
||||||
<link rel="stylesheet" href="http://getbootstrap.com/assets/css/docs.min.css">
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
{{> head }}
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div class="container">
|
|
||||||
{{> body }}
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,35 +0,0 @@
|
|||||||
module.exports = api => {
|
|
||||||
api.cache.using(() => {
|
|
||||||
// cache based on the two env vars
|
|
||||||
return (
|
|
||||||
'babel:' +
|
|
||||||
process.env.BABEL_TARGET +
|
|
||||||
' protractor:' +
|
|
||||||
process.env.IN_PROTRACTOR
|
|
||||||
);
|
|
||||||
});
|
|
||||||
|
|
||||||
return {
|
|
||||||
plugins: [
|
|
||||||
['@babel/plugin-proposal-decorators', { legacy: true }],
|
|
||||||
['@babel/plugin-proposal-class-properties', { loose: true }],
|
|
||||||
],
|
|
||||||
presets: [
|
|
||||||
[
|
|
||||||
'@babel/preset-env',
|
|
||||||
{
|
|
||||||
targets:
|
|
||||||
process.env.BABEL_TARGET === 'node'
|
|
||||||
? {
|
|
||||||
node: process.env.IN_PROTRACTOR ? '6' : 'current',
|
|
||||||
}
|
|
||||||
: {
|
|
||||||
browsers: ['last 2 versions'],
|
|
||||||
},
|
|
||||||
loose: true,
|
|
||||||
modules: process.env.BABEL_TARGET === 'node' ? 'commonjs' : false,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
],
|
|
||||||
};
|
|
||||||
};
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
# EditorConfig is awesome: http://EditorConfig.org
|
|
||||||
|
|
||||||
# top-most EditorConfig file
|
|
||||||
root = true
|
|
||||||
|
|
||||||
# Unix-style newlines with a newline ending every file
|
|
||||||
[*]
|
|
||||||
end_of_line = lf
|
|
||||||
insert_final_newline = true
|
|
||||||
# 2 space indentation
|
|
||||||
indent_style = space
|
|
||||||
indent_size = 2
|
|
||||||
41
examples/aurelia/.gitignore
vendored
41
examples/aurelia/.gitignore
vendored
@@ -1,41 +0,0 @@
|
|||||||
|
|
||||||
# You may want to customise this file depending on your Operating System
|
|
||||||
# and the editor that you use.
|
|
||||||
#
|
|
||||||
# We recommend that you use a Global Gitignore for files that are not related
|
|
||||||
# to the project. (https://help.github.com/articles/ignoring-files/#create-a-global-gitignore)
|
|
||||||
|
|
||||||
# OS
|
|
||||||
#
|
|
||||||
# Ref: https://github.com/github/gitignore/blob/master/Global/macOS.gitignore
|
|
||||||
# Ref: https://github.com/github/gitignore/blob/master/Global/Windows.gitignore
|
|
||||||
# Ref: https://github.com/github/gitignore/blob/master/Global/Linux.gitignore
|
|
||||||
.DS_STORE
|
|
||||||
Thumbs.db
|
|
||||||
|
|
||||||
# Editors
|
|
||||||
#
|
|
||||||
# Ref: https://github.com/github/gitignore/blob/master/Global
|
|
||||||
# Ref: https://github.com/github/gitignore/blob/master/Global/JetBrains.gitignore
|
|
||||||
# Ref: https://github.com/github/gitignore/blob/master/Global/VisualStudioCode.gitignore
|
|
||||||
.idea
|
|
||||||
.vscode/*
|
|
||||||
!.vscode/settings.json
|
|
||||||
!.vscode/tasks.json
|
|
||||||
!.vscode/launch.json
|
|
||||||
!.vscode/extensions.json
|
|
||||||
|
|
||||||
# Dependencies
|
|
||||||
node_modules
|
|
||||||
|
|
||||||
# Compiled files
|
|
||||||
/scripts
|
|
||||||
/src/environment.js
|
|
||||||
/src/environment.ts
|
|
||||||
/dist
|
|
||||||
/test/coverage-jest
|
|
||||||
/test/coverage-karma
|
|
||||||
|
|
||||||
# Environment Variables
|
|
||||||
.env
|
|
||||||
.env.build
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
README.md
|
|
||||||
yarn.lock
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
# Aurelia Example
|
|
||||||
|
|
||||||
This directory is a brief example of an [Aurelia](https://aurelia.io/) app that can be deployed with ZEIT Now and zero configuration.
|
|
||||||
|
|
||||||
## Deploy Your Own
|
|
||||||
|
|
||||||
Deploy your own Aurelia project with ZEIT Now.
|
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/aurelia)
|
|
||||||
|
|
||||||
_Live Example: https://aurelia.now-examples.now.sh_
|
|
||||||
|
|
||||||
### How We Created This Example
|
|
||||||
|
|
||||||
To get started deploying Aurelia with ZEIT Now, you can use the [Aurelia CLI](https://aurelia.io/docs/cli/basics/) to initialize the project:
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ au new
|
|
||||||
```
|
|
||||||
|
|
||||||
### Deploying From Your Terminal
|
|
||||||
|
|
||||||
You can deploy your new Aurelia project with a single command from your terminal using [Now CLI](https://zeit.co/download):
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now
|
|
||||||
```
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "aurelia",
|
|
||||||
"type": "project:application",
|
|
||||||
"paths": {
|
|
||||||
"root": "src",
|
|
||||||
"resources": "resources",
|
|
||||||
"elements": "resources/elements",
|
|
||||||
"attributes": "resources/attributes",
|
|
||||||
"valueConverters": "resources/value-converters",
|
|
||||||
"bindingBehaviors": "resources/binding-behaviors"
|
|
||||||
},
|
|
||||||
"transpiler": {
|
|
||||||
"id": "babel",
|
|
||||||
"fileExtension": ".js"
|
|
||||||
},
|
|
||||||
"build": {
|
|
||||||
"options": {
|
|
||||||
"server": "dev",
|
|
||||||
"extractCss": "prod",
|
|
||||||
"coverage": false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"platform": {
|
|
||||||
"hmr": false,
|
|
||||||
"open": false,
|
|
||||||
"port": 8080,
|
|
||||||
"output": "public"
|
|
||||||
},
|
|
||||||
"packageManager": "yarn"
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
export default {
|
|
||||||
debug: true,
|
|
||||||
testing: true,
|
|
||||||
};
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
export default {
|
|
||||||
debug: false,
|
|
||||||
testing: false,
|
|
||||||
};
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
export default {
|
|
||||||
debug: true,
|
|
||||||
testing: false,
|
|
||||||
};
|
|
||||||
@@ -1,44 +0,0 @@
|
|||||||
import { inject } from 'aurelia-dependency-injection';
|
|
||||||
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class AttributeGenerator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
async execute() {
|
|
||||||
const name = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[0],
|
|
||||||
'What would you like to call the custom attribute?'
|
|
||||||
);
|
|
||||||
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let className = this.project.makeClassName(name);
|
|
||||||
|
|
||||||
this.project.attributes.add(
|
|
||||||
ProjectItem.text(`${fileName}.js`, this.generateSource(className))
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.project.commitChanges();
|
|
||||||
await this.ui.log(`Created ${fileName}.`);
|
|
||||||
}
|
|
||||||
|
|
||||||
generateSource(className) {
|
|
||||||
return `import {inject} from 'aurelia-framework';
|
|
||||||
|
|
||||||
@inject(Element)
|
|
||||||
export class ${className}CustomAttribute {
|
|
||||||
constructor(element) {
|
|
||||||
this.element = element;
|
|
||||||
}
|
|
||||||
|
|
||||||
valueChanged(newValue, oldValue) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "attribute",
|
|
||||||
"description": "Creates a custom attribute class and places it in the project resources."
|
|
||||||
}
|
|
||||||
@@ -1,41 +0,0 @@
|
|||||||
import { inject } from 'aurelia-dependency-injection';
|
|
||||||
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class BindingBehaviorGenerator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
async execute() {
|
|
||||||
const name = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[0],
|
|
||||||
'What would you like to call the binding behavior?'
|
|
||||||
);
|
|
||||||
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let className = this.project.makeClassName(name);
|
|
||||||
|
|
||||||
this.project.bindingBehaviors.add(
|
|
||||||
ProjectItem.text(`${fileName}.js`, this.generateSource(className))
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.project.commitChanges();
|
|
||||||
await this.ui.log(`Created ${fileName}.`);
|
|
||||||
}
|
|
||||||
|
|
||||||
generateSource(className) {
|
|
||||||
return `export class ${className}BindingBehavior {
|
|
||||||
bind(binding, source) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
|
|
||||||
unbind(binding, source) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "binding-behavior",
|
|
||||||
"description": "Creates a binding behavior class and places it in the project resources."
|
|
||||||
}
|
|
||||||
@@ -1,64 +0,0 @@
|
|||||||
import { inject } from 'aurelia-dependency-injection';
|
|
||||||
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';
|
|
||||||
|
|
||||||
var path = require('path');
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class ElementGenerator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
async execute() {
|
|
||||||
const name = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[0],
|
|
||||||
'What would you like to call the component?'
|
|
||||||
);
|
|
||||||
|
|
||||||
const subFolders = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[1],
|
|
||||||
"What sub-folder would you like to add it to?\nIf it doesn't exist it will be created for you.\n\nDefault folder is the source folder (src).",
|
|
||||||
'.'
|
|
||||||
);
|
|
||||||
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let className = this.project.makeClassName(name);
|
|
||||||
|
|
||||||
this.project.root.add(
|
|
||||||
ProjectItem.text(
|
|
||||||
path.join(subFolders, fileName + '.js'),
|
|
||||||
this.generateJSSource(className)
|
|
||||||
),
|
|
||||||
ProjectItem.text(
|
|
||||||
path.join(subFolders, fileName + '.html'),
|
|
||||||
this.generateHTMLSource(className)
|
|
||||||
)
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.project.commitChanges();
|
|
||||||
await this.ui.log(
|
|
||||||
`Created ${name} in the '${path.join(
|
|
||||||
this.project.root.name,
|
|
||||||
subFolders
|
|
||||||
)}' folder`
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
generateJSSource(className) {
|
|
||||||
return `export class ${className} {
|
|
||||||
constructor() {
|
|
||||||
this.message = 'Hello world';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
|
|
||||||
generateHTMLSource(className) {
|
|
||||||
return `<template>
|
|
||||||
<h1>\${message}</h1>
|
|
||||||
</template>
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "component",
|
|
||||||
"description": "Creates a custom component class and template (view model and view), placing them in the project source folder (or optionally in sub folders)."
|
|
||||||
}
|
|
||||||
@@ -1,49 +0,0 @@
|
|||||||
import { inject } from 'aurelia-dependency-injection';
|
|
||||||
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class ElementGenerator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
async execute() {
|
|
||||||
const name = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[0],
|
|
||||||
'What would you like to call the custom element?'
|
|
||||||
);
|
|
||||||
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let className = this.project.makeClassName(name);
|
|
||||||
|
|
||||||
this.project.elements.add(
|
|
||||||
ProjectItem.text(`${fileName}.js`, this.generateJSSource(className)),
|
|
||||||
ProjectItem.text(`${fileName}.html`, this.generateHTMLSource(className))
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.project.commitChanges();
|
|
||||||
await this.ui.log(`Created ${fileName}.`);
|
|
||||||
}
|
|
||||||
|
|
||||||
generateJSSource(className) {
|
|
||||||
return `import {bindable} from 'aurelia-framework';
|
|
||||||
|
|
||||||
export class ${className} {
|
|
||||||
@bindable value;
|
|
||||||
|
|
||||||
valueChanged(newValue, oldValue) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
|
|
||||||
generateHTMLSource(className) {
|
|
||||||
return `<template>
|
|
||||||
<h1>\${value}</h1>
|
|
||||||
</template>
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "element",
|
|
||||||
"description": "Creates a custom element class and template, placing them in the project resources."
|
|
||||||
}
|
|
||||||
@@ -1,72 +0,0 @@
|
|||||||
import { inject } from 'aurelia-dependency-injection';
|
|
||||||
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class GeneratorGenerator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
async execute() {
|
|
||||||
const name = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[0],
|
|
||||||
'What would you like to call the generator?'
|
|
||||||
);
|
|
||||||
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let className = this.project.makeClassName(name);
|
|
||||||
|
|
||||||
this.project.generators.add(
|
|
||||||
ProjectItem.text(`${fileName}.js`, this.generateSource(className))
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.project.commitChanges();
|
|
||||||
await this.ui.log(`Created ${fileName}.`);
|
|
||||||
}
|
|
||||||
|
|
||||||
generateSource(className) {
|
|
||||||
return `import {inject} from 'aurelia-dependency-injection';
|
|
||||||
import {Project, ProjectItem, CLIOptions, UI} from 'aurelia-cli';
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class ${className}Generator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
execute() {
|
|
||||||
return this.ui
|
|
||||||
.ensureAnswer(this.options.args[0], 'What would you like to call the new item?')
|
|
||||||
.then(name => {
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let className = this.project.makeClassName(name);
|
|
||||||
|
|
||||||
this.project.elements.add(
|
|
||||||
ProjectItem.text(\`\${fileName}.js\`, this.generateSource(className))
|
|
||||||
);
|
|
||||||
|
|
||||||
return this.project.commitChanges()
|
|
||||||
.then(() => this.ui.log(\`Created \${fileName}.\`));
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
generateSource(className) {
|
|
||||||
return \`import {bindable} from 'aurelia-framework';
|
|
||||||
|
|
||||||
export class \${className} {
|
|
||||||
@bindable value;
|
|
||||||
|
|
||||||
valueChanged(newValue, oldValue) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
|
||||||
\`
|
|
||||||
}
|
|
||||||
}
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "generator",
|
|
||||||
"description": "Creates a generator class and places it in the project generators folder."
|
|
||||||
}
|
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
import { inject } from 'aurelia-dependency-injection';
|
|
||||||
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class TaskGenerator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
async execute() {
|
|
||||||
const name = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[0],
|
|
||||||
'What would you like to call the task?'
|
|
||||||
);
|
|
||||||
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let functionName = this.project.makeFunctionName(name);
|
|
||||||
|
|
||||||
this.project.tasks.add(
|
|
||||||
ProjectItem.text(`${fileName}.js`, this.generateSource(functionName))
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.project.commitChanges();
|
|
||||||
await this.ui.log(`Created ${fileName}.`);
|
|
||||||
}
|
|
||||||
|
|
||||||
generateSource(functionName) {
|
|
||||||
return `import gulp from 'gulp';
|
|
||||||
import project from '../aurelia.json';
|
|
||||||
|
|
||||||
export default function ${functionName}() {
|
|
||||||
return gulp.src(project.paths.???)
|
|
||||||
.pipe(gulp.dest(project.paths.output));
|
|
||||||
}
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "task",
|
|
||||||
"description": "Creates a task and places it in the project tasks folder."
|
|
||||||
}
|
|
||||||
@@ -1,41 +0,0 @@
|
|||||||
import { inject } from 'aurelia-dependency-injection';
|
|
||||||
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';
|
|
||||||
|
|
||||||
@inject(Project, CLIOptions, UI)
|
|
||||||
export default class ValueConverterGenerator {
|
|
||||||
constructor(project, options, ui) {
|
|
||||||
this.project = project;
|
|
||||||
this.options = options;
|
|
||||||
this.ui = ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
async execute() {
|
|
||||||
const name = await this.ui.ensureAnswer(
|
|
||||||
this.options.args[0],
|
|
||||||
'What would you like to call the value converter?'
|
|
||||||
);
|
|
||||||
|
|
||||||
let fileName = this.project.makeFileName(name);
|
|
||||||
let className = this.project.makeClassName(name);
|
|
||||||
|
|
||||||
this.project.valueConverters.add(
|
|
||||||
ProjectItem.text(`${fileName}.js`, this.generateSource(className))
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.project.commitChanges();
|
|
||||||
await this.ui.log(`Created ${fileName}.`);
|
|
||||||
}
|
|
||||||
|
|
||||||
generateSource(className) {
|
|
||||||
return `export class ${className}ValueConverter {
|
|
||||||
toView(value) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
|
|
||||||
fromView(value) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
|
||||||
`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "value-converter",
|
|
||||||
"description": "Creates a value converter class and places it in the project resources."
|
|
||||||
}
|
|
||||||
@@ -1,56 +0,0 @@
|
|||||||
import webpackConfig from '../../webpack.config';
|
|
||||||
import webpack from 'webpack';
|
|
||||||
import project from '../aurelia.json';
|
|
||||||
import gulp from 'gulp';
|
|
||||||
import del from 'del';
|
|
||||||
import { CLIOptions, Configuration } from 'aurelia-cli';
|
|
||||||
import configureEnvironment from './environment';
|
|
||||||
|
|
||||||
const analyze = CLIOptions.hasFlag('analyze');
|
|
||||||
const buildOptions = new Configuration(project.build.options);
|
|
||||||
const production = CLIOptions.getEnvironment() === 'prod';
|
|
||||||
const server = buildOptions.isApplicable('server');
|
|
||||||
const extractCss = buildOptions.isApplicable('extractCss');
|
|
||||||
const coverage = buildOptions.isApplicable('coverage');
|
|
||||||
|
|
||||||
const config = webpackConfig({
|
|
||||||
production,
|
|
||||||
server,
|
|
||||||
extractCss,
|
|
||||||
coverage,
|
|
||||||
analyze,
|
|
||||||
});
|
|
||||||
const compiler = webpack(config);
|
|
||||||
|
|
||||||
function buildWebpack(done) {
|
|
||||||
if (CLIOptions.hasFlag('watch')) {
|
|
||||||
compiler.watch({}, onBuild);
|
|
||||||
} else {
|
|
||||||
compiler.run(onBuild);
|
|
||||||
compiler.hooks.done.tap('done', () => done());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function onBuild(err, stats) {
|
|
||||||
if (!CLIOptions.hasFlag('watch') && err) {
|
|
||||||
console.error(err.stack || err);
|
|
||||||
if (err.details) console.error(err.details);
|
|
||||||
process.exit(1);
|
|
||||||
} else {
|
|
||||||
process.stdout.write(
|
|
||||||
stats.toString({ colors: require('supports-color') }) + '\n'
|
|
||||||
);
|
|
||||||
|
|
||||||
if (!CLIOptions.hasFlag('watch') && stats.hasErrors()) {
|
|
||||||
process.exit(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function clearDist() {
|
|
||||||
return del([config.output.path]);
|
|
||||||
}
|
|
||||||
|
|
||||||
const build = gulp.series(clearDist, configureEnvironment, buildWebpack);
|
|
||||||
|
|
||||||
export { config, buildWebpack, build as default };
|
|
||||||
@@ -1,21 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "build",
|
|
||||||
"description": "Builds and processes all application assets.",
|
|
||||||
"flags": [
|
|
||||||
{
|
|
||||||
"name": "analyze",
|
|
||||||
"description": "Enable Webpack Bundle Analyzer. Typically paired with --env prod",
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "env",
|
|
||||||
"description": "Sets the build environment.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "watch",
|
|
||||||
"description": "Watches source files for changes and refreshes the bundles automatically.",
|
|
||||||
"type": "boolean"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
import project from '../aurelia.json';
|
|
||||||
import rename from 'gulp-rename';
|
|
||||||
import gulp from 'gulp';
|
|
||||||
import fs from 'fs';
|
|
||||||
import through from 'through2';
|
|
||||||
import { CLIOptions } from 'aurelia-cli';
|
|
||||||
|
|
||||||
function configureEnvironment() {
|
|
||||||
let env = CLIOptions.getEnvironment();
|
|
||||||
|
|
||||||
return gulp
|
|
||||||
.src(
|
|
||||||
`aurelia_project/environments/${env}${project.transpiler.fileExtension}`
|
|
||||||
)
|
|
||||||
.pipe(rename(`environment${project.transpiler.fileExtension}`))
|
|
||||||
.pipe(
|
|
||||||
through.obj(function(file, _, cb) {
|
|
||||||
// https://github.com/aurelia/cli/issues/1031
|
|
||||||
fs.unlink(`${project.paths.root}/${file.relative}`, function() {
|
|
||||||
cb(null, file);
|
|
||||||
});
|
|
||||||
})
|
|
||||||
)
|
|
||||||
.pipe(gulp.dest(project.paths.root))
|
|
||||||
.pipe(
|
|
||||||
through.obj(function(file, enc, cb) {
|
|
||||||
// https://github.com/webpack/watchpack/issues/25#issuecomment-287789288
|
|
||||||
const now = Date.now() / 1000;
|
|
||||||
const then = now - 10;
|
|
||||||
fs.utimes(file.path, then, then, function(err) {
|
|
||||||
if (err) throw err;
|
|
||||||
});
|
|
||||||
cb(null, file);
|
|
||||||
})
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
export default configureEnvironment;
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
export { default } from './test';
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "jest",
|
|
||||||
"description": "Runs Jest and reports the results.",
|
|
||||||
"flags": [
|
|
||||||
{
|
|
||||||
"name": "watch",
|
|
||||||
"description": "Watches test files for changes and re-runs the tests automatically.",
|
|
||||||
"type": "boolean"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,54 +0,0 @@
|
|||||||
import webpack from 'webpack';
|
|
||||||
import Server from 'webpack-dev-server';
|
|
||||||
import project from '../aurelia.json';
|
|
||||||
import gulp from 'gulp';
|
|
||||||
|
|
||||||
import { config } from './build';
|
|
||||||
import configureEnvironment from './environment';
|
|
||||||
import { CLIOptions, reportWebpackReadiness } from 'aurelia-cli';
|
|
||||||
|
|
||||||
function runWebpack(done) {
|
|
||||||
// https://webpack.github.io/docs/webpack-dev-server.html
|
|
||||||
let opts = {
|
|
||||||
host: 'localhost',
|
|
||||||
publicPath: config.output.publicPath,
|
|
||||||
filename: config.output.filename,
|
|
||||||
hot: project.platform.hmr || CLIOptions.hasFlag('hmr'),
|
|
||||||
port: CLIOptions.getFlagValue('port') || project.platform.port,
|
|
||||||
contentBase: config.output.path,
|
|
||||||
historyApiFallback: true,
|
|
||||||
open: project.platform.open || CLIOptions.hasFlag('open'),
|
|
||||||
stats: {
|
|
||||||
colors: require('supports-color'),
|
|
||||||
},
|
|
||||||
...config.devServer,
|
|
||||||
};
|
|
||||||
|
|
||||||
// Add the webpack-dev-server client to the webpack entry point
|
|
||||||
// The path for the client to use such as `webpack-dev-server/client?http://${opts.host}:${opts.port}/` is not required
|
|
||||||
// The path used is derived from window.location in the browser and output.publicPath in the webpack.config.
|
|
||||||
if (project.platform.hmr || CLIOptions.hasFlag('hmr')) {
|
|
||||||
config.plugins.push(new webpack.HotModuleReplacementPlugin());
|
|
||||||
config.entry.app.unshift(
|
|
||||||
'webpack-dev-server/client',
|
|
||||||
'webpack/hot/dev-server'
|
|
||||||
);
|
|
||||||
} else {
|
|
||||||
// removed "<script src="/webpack-dev-server.js"></script>" from index.ejs in favour of this method
|
|
||||||
config.entry.app.unshift('webpack-dev-server/client');
|
|
||||||
}
|
|
||||||
|
|
||||||
const compiler = webpack(config);
|
|
||||||
let server = new Server(compiler, opts);
|
|
||||||
|
|
||||||
server.listen(opts.port, opts.host, function(err) {
|
|
||||||
if (err) throw err;
|
|
||||||
|
|
||||||
reportWebpackReadiness(opts);
|
|
||||||
done();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
const run = gulp.series(configureEnvironment, runWebpack);
|
|
||||||
|
|
||||||
export { run as default };
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "run",
|
|
||||||
"description": "Builds the application and serves up the assets via a local web server, watching files for changes as you work.",
|
|
||||||
"flags": [
|
|
||||||
{
|
|
||||||
"name": "analyze",
|
|
||||||
"description": "Enable Webpack Bundle Analyzer. Typically paired with --env prod",
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "env",
|
|
||||||
"description": "Sets the build environment.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "hmr",
|
|
||||||
"description": "Enable Hot Module Reload",
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "port",
|
|
||||||
"description": "Set port number of the dev server",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "open",
|
|
||||||
"description": "Open the default browser at the application location.",
|
|
||||||
"type": "boolean"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
import jest from 'jest-cli';
|
|
||||||
import path from 'path';
|
|
||||||
import packageJson from '../../package.json';
|
|
||||||
|
|
||||||
import { CLIOptions } from 'aurelia-cli';
|
|
||||||
|
|
||||||
export default cb => {
|
|
||||||
let options = packageJson.jest;
|
|
||||||
|
|
||||||
if (CLIOptions.hasFlag('watch')) {
|
|
||||||
Object.assign(options, { watchAll: true });
|
|
||||||
}
|
|
||||||
|
|
||||||
process.env.BABEL_TARGET = 'node';
|
|
||||||
|
|
||||||
jest
|
|
||||||
.runCLI(options, [path.resolve(__dirname, '../../')])
|
|
||||||
.then(({ results }) => {
|
|
||||||
if (results.numFailedTests || results.numFailedTestSuites) {
|
|
||||||
cb('Tests Failed');
|
|
||||||
} else {
|
|
||||||
cb();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
};
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "test",
|
|
||||||
"description": "Runs Jest and reports the results.",
|
|
||||||
"flags": [
|
|
||||||
{
|
|
||||||
"name": "watch",
|
|
||||||
"description": "Watches test files for changes and re-runs the tests automatically.",
|
|
||||||
"type": "boolean"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB |
@@ -1,12 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html>
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<title><%- htmlWebpackPlugin.options.metadata.title %></title>
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
||||||
<base href="<%- htmlWebpackPlugin.options.metadata.baseUrl %>">
|
|
||||||
<!-- imported CSS are concatenated and added automatically -->
|
|
||||||
</head>
|
|
||||||
<body aurelia-app="main">
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
{
|
|
||||||
"compilerOptions": {
|
|
||||||
"target": "es2015",
|
|
||||||
"lib": ["es2017", "dom"],
|
|
||||||
"experimentalDecorators": true
|
|
||||||
},
|
|
||||||
"exclude": ["node_modules", "dist"]
|
|
||||||
}
|
|
||||||
@@ -1,104 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "aurelia",
|
|
||||||
"description": "An Aurelia client application.",
|
|
||||||
"version": "0.1.0",
|
|
||||||
"repository": {
|
|
||||||
"type": "???",
|
|
||||||
"url": "???"
|
|
||||||
},
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"aurelia-bootstrapper": "^2.3.2",
|
|
||||||
"aurelia-animator-css": "^1.0.4"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"aurelia-cli": "^1.0.2",
|
|
||||||
"aurelia-testing": "^1.0.0",
|
|
||||||
"aurelia-tools": "^2.0.0",
|
|
||||||
"gulp": "^4.0.0",
|
|
||||||
"minimatch": "^3.0.4",
|
|
||||||
"through2": "^3.0.0",
|
|
||||||
"vinyl-fs": "^3.0.3",
|
|
||||||
"promise-polyfill": "^8.1.0",
|
|
||||||
"regenerator-runtime": "0.13.2",
|
|
||||||
"babel-eslint": "^10.0.1",
|
|
||||||
"eslint": "latest",
|
|
||||||
"babel-loader": "^8.0.5",
|
|
||||||
"babel-plugin-istanbul": "^5.1.1",
|
|
||||||
"@babel/plugin-proposal-decorators": "^7.4.0",
|
|
||||||
"@babel/plugin-proposal-class-properties": "^7.4.0",
|
|
||||||
"@babel/preset-env": "^7.4.2",
|
|
||||||
"@babel/core": "^7.4.0",
|
|
||||||
"@babel/register": "^7.4.0",
|
|
||||||
"gulp-rename": "^1.4.0",
|
|
||||||
"html-webpack-plugin": "^3.2.0",
|
|
||||||
"copy-webpack-plugin": "^5.0.0",
|
|
||||||
"mini-css-extract-plugin": "^0.4.3",
|
|
||||||
"aurelia-webpack-plugin": "^3.0.0",
|
|
||||||
"duplicate-package-checker-webpack-plugin": "^3.0.0",
|
|
||||||
"webpack": "^4.27.0",
|
|
||||||
"webpack-cli": "^3.1.2",
|
|
||||||
"webpack-dev-server": "^3.1.9",
|
|
||||||
"expose-loader": "^0.7.5",
|
|
||||||
"style-loader": "^0.23.1",
|
|
||||||
"url-loader": "^1.1.2",
|
|
||||||
"del": "^3.0.0",
|
|
||||||
"css-loader": "^1.0.0",
|
|
||||||
"file-loader": "^2.0.0",
|
|
||||||
"json-loader": "^0.5.7",
|
|
||||||
"html-loader": "^0.5.5",
|
|
||||||
"istanbul-instrumenter-loader": "^3.0.1",
|
|
||||||
"webpack-bundle-analyzer": "^3.0.4",
|
|
||||||
"jest": "^24.1.0",
|
|
||||||
"jest-cli": "^24.1.0",
|
|
||||||
"jest-transform-stub": "^2.0.0",
|
|
||||||
"aurelia-loader-nodejs": "^1.0.1",
|
|
||||||
"aurelia-pal-nodejs": "^1.2.0",
|
|
||||||
"babel-jest": "^24.5.0"
|
|
||||||
},
|
|
||||||
"scripts": {
|
|
||||||
"build": "au build",
|
|
||||||
"start": "au run",
|
|
||||||
"dev": "au run --port $PORT",
|
|
||||||
"test": "au test"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8.9.0"
|
|
||||||
},
|
|
||||||
"jest": {
|
|
||||||
"moduleNameMapper": {
|
|
||||||
"^aurelia-binding$": "<rootDir>/node_modules/aurelia-binding"
|
|
||||||
},
|
|
||||||
"modulePaths": [
|
|
||||||
"<rootDir>/src",
|
|
||||||
"<rootDir>/node_modules"
|
|
||||||
],
|
|
||||||
"moduleFileExtensions": [
|
|
||||||
"js",
|
|
||||||
"json"
|
|
||||||
],
|
|
||||||
"transform": {
|
|
||||||
"^.+\\.(css|less|sass|scss|styl|jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "jest-transform-stub",
|
|
||||||
"^.+\\.js$": "babel-jest"
|
|
||||||
},
|
|
||||||
"testRegex": "\\.spec\\.js$",
|
|
||||||
"setupFiles": [
|
|
||||||
"<rootDir>/test/jest-pretest.js"
|
|
||||||
],
|
|
||||||
"testEnvironment": "node",
|
|
||||||
"collectCoverage": true,
|
|
||||||
"collectCoverageFrom": [
|
|
||||||
"src/**/*.js",
|
|
||||||
"!**/*.spec.js",
|
|
||||||
"!**/node_modules/**",
|
|
||||||
"!**/test/**"
|
|
||||||
],
|
|
||||||
"coverageDirectory": "<rootDir>/test/coverage-jest",
|
|
||||||
"coverageReporters": [
|
|
||||||
"json",
|
|
||||||
"lcov",
|
|
||||||
"text",
|
|
||||||
"html"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
<template>
|
|
||||||
<h1>${message}</h1>
|
|
||||||
</template>
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
export class App {
|
|
||||||
message = 'Hello World!';
|
|
||||||
}
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
// regenerator-runtime is to support async/await syntax in ESNext.
|
|
||||||
// If you don't use async/await, you can remove regenerator-runtime.
|
|
||||||
import 'regenerator-runtime/runtime';
|
|
||||||
import environment from './environment';
|
|
||||||
import { PLATFORM } from 'aurelia-pal';
|
|
||||||
|
|
||||||
export function configure(aurelia) {
|
|
||||||
aurelia.use
|
|
||||||
.standardConfiguration()
|
|
||||||
.feature(PLATFORM.moduleName('resources/index'));
|
|
||||||
|
|
||||||
aurelia.use.developmentLogging(environment.debug ? 'debug' : 'warn');
|
|
||||||
|
|
||||||
if (environment.testing) {
|
|
||||||
aurelia.use.plugin(PLATFORM.moduleName('aurelia-testing'));
|
|
||||||
}
|
|
||||||
|
|
||||||
aurelia.start().then(() => aurelia.setRoot(PLATFORM.moduleName('app')));
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
export function configure(config) {
|
|
||||||
//config.globalResources([]);
|
|
||||||
}
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB |
@@ -1,6 +0,0 @@
|
|||||||
import 'aurelia-polyfills';
|
|
||||||
import { Options } from 'aurelia-loader-nodejs';
|
|
||||||
import { globalize } from 'aurelia-pal-nodejs';
|
|
||||||
import path from 'path';
|
|
||||||
Options.relativeToDir = path.join(__dirname, 'unit');
|
|
||||||
globalize();
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
"rules": {
|
|
||||||
"no-var": 0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
import { bootstrap } from 'aurelia-bootstrapper';
|
|
||||||
import { StageComponent } from 'aurelia-testing';
|
|
||||||
import { PLATFORM } from 'aurelia-pal';
|
|
||||||
|
|
||||||
describe('Stage App Component', () => {
|
|
||||||
let component;
|
|
||||||
|
|
||||||
beforeEach(() => {
|
|
||||||
component = StageComponent.withResources(PLATFORM.moduleName('app')).inView(
|
|
||||||
'<app></app>'
|
|
||||||
);
|
|
||||||
});
|
|
||||||
|
|
||||||
afterEach(() => component.dispose());
|
|
||||||
|
|
||||||
it('should render message', done => {
|
|
||||||
component
|
|
||||||
.create(bootstrap)
|
|
||||||
.then(() => {
|
|
||||||
const view = component.element;
|
|
||||||
expect(view.textContent.trim()).toBe('Hello World!');
|
|
||||||
done();
|
|
||||||
})
|
|
||||||
.catch(e => {
|
|
||||||
fail(e);
|
|
||||||
done();
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
||||||
@@ -1,224 +0,0 @@
|
|||||||
const path = require('path');
|
|
||||||
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
|
||||||
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
|
||||||
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
|
|
||||||
const DuplicatePackageCheckerPlugin = require('duplicate-package-checker-webpack-plugin');
|
|
||||||
const project = require('./aurelia_project/aurelia.json');
|
|
||||||
const {
|
|
||||||
AureliaPlugin,
|
|
||||||
ModuleDependenciesPlugin,
|
|
||||||
} = require('aurelia-webpack-plugin');
|
|
||||||
const { ProvidePlugin } = require('webpack');
|
|
||||||
const { BundleAnalyzerPlugin } = require('webpack-bundle-analyzer');
|
|
||||||
|
|
||||||
// config helpers:
|
|
||||||
const ensureArray = config =>
|
|
||||||
(config && (Array.isArray(config) ? config : [config])) || [];
|
|
||||||
const when = (condition, config, negativeConfig) =>
|
|
||||||
condition ? ensureArray(config) : ensureArray(negativeConfig);
|
|
||||||
|
|
||||||
// primary config:
|
|
||||||
const title = 'Aurelia Navigation Skeleton';
|
|
||||||
const outDir = path.resolve(__dirname, project.platform.output);
|
|
||||||
const srcDir = path.resolve(__dirname, 'src');
|
|
||||||
const testDir = path.resolve(__dirname, 'test', 'unit');
|
|
||||||
const nodeModulesDir = path.resolve(__dirname, 'node_modules');
|
|
||||||
const baseUrl = '/';
|
|
||||||
|
|
||||||
const cssRules = [{ loader: 'css-loader' }];
|
|
||||||
|
|
||||||
module.exports = ({
|
|
||||||
production,
|
|
||||||
server,
|
|
||||||
extractCss,
|
|
||||||
coverage,
|
|
||||||
analyze,
|
|
||||||
karma,
|
|
||||||
} = {}) => ({
|
|
||||||
resolve: {
|
|
||||||
extensions: ['.js'],
|
|
||||||
modules: [srcDir, 'node_modules'],
|
|
||||||
// Enforce single aurelia-binding, to avoid v1/v2 duplication due to
|
|
||||||
// out-of-date dependencies on 3rd party aurelia plugins
|
|
||||||
alias: {
|
|
||||||
'aurelia-binding': path.resolve(
|
|
||||||
__dirname,
|
|
||||||
'node_modules/aurelia-binding'
|
|
||||||
),
|
|
||||||
},
|
|
||||||
},
|
|
||||||
entry: {
|
|
||||||
app: ['aurelia-bootstrapper'],
|
|
||||||
},
|
|
||||||
mode: production ? 'production' : 'development',
|
|
||||||
output: {
|
|
||||||
path: outDir,
|
|
||||||
publicPath: baseUrl,
|
|
||||||
filename: production
|
|
||||||
? '[name].[chunkhash].bundle.js'
|
|
||||||
: '[name].[hash].bundle.js',
|
|
||||||
sourceMapFilename: production
|
|
||||||
? '[name].[chunkhash].bundle.map'
|
|
||||||
: '[name].[hash].bundle.map',
|
|
||||||
chunkFilename: production
|
|
||||||
? '[name].[chunkhash].chunk.js'
|
|
||||||
: '[name].[hash].chunk.js',
|
|
||||||
},
|
|
||||||
optimization: {
|
|
||||||
runtimeChunk: true, // separates the runtime chunk, required for long term cacheability
|
|
||||||
// moduleIds is the replacement for HashedModuleIdsPlugin and NamedModulesPlugin deprecated in https://github.com/webpack/webpack/releases/tag/v4.16.0
|
|
||||||
// changes module id's to use hashes be based on the relative path of the module, required for long term cacheability
|
|
||||||
moduleIds: 'hashed',
|
|
||||||
// Use splitChunks to breakdown the App/Aurelia bundle down into smaller chunks
|
|
||||||
// https://webpack.js.org/plugins/split-chunks-plugin/
|
|
||||||
splitChunks: {
|
|
||||||
hidePathInfo: true, // prevents the path from being used in the filename when using maxSize
|
|
||||||
chunks: 'initial',
|
|
||||||
// sizes are compared against source before minification
|
|
||||||
maxSize: 200000, // splits chunks if bigger than 200k, adjust as required (maxSize added in webpack v4.15)
|
|
||||||
cacheGroups: {
|
|
||||||
default: false, // Disable the built-in groups default & vendors (vendors is redefined below)
|
|
||||||
// You can insert additional cacheGroup entries here if you want to split out specific modules
|
|
||||||
// This is required in order to split out vendor css from the app css when using --extractCss
|
|
||||||
// For example to separate font-awesome and bootstrap:
|
|
||||||
// fontawesome: { // separates font-awesome css from the app css (font-awesome is only css/fonts)
|
|
||||||
// name: 'vendor.font-awesome',
|
|
||||||
// test: /[\\/]node_modules[\\/]font-awesome[\\/]/,
|
|
||||||
// priority: 100,
|
|
||||||
// enforce: true
|
|
||||||
// },
|
|
||||||
// bootstrap: { // separates bootstrap js from vendors and also bootstrap css from app css
|
|
||||||
// name: 'vendor.font-awesome',
|
|
||||||
// test: /[\\/]node_modules[\\/]bootstrap[\\/]/,
|
|
||||||
// priority: 90,
|
|
||||||
// enforce: true
|
|
||||||
// },
|
|
||||||
|
|
||||||
// This is the HTTP/1.1 optimised cacheGroup configuration
|
|
||||||
vendors: {
|
|
||||||
// picks up everything from node_modules as long as the sum of node modules is larger than minSize
|
|
||||||
test: /[\\/]node_modules[\\/]/,
|
|
||||||
name: 'vendors',
|
|
||||||
priority: 19,
|
|
||||||
enforce: true, // causes maxInitialRequests to be ignored, minSize still respected if specified in cacheGroup
|
|
||||||
minSize: 30000, // use the default minSize
|
|
||||||
},
|
|
||||||
vendorsAsync: {
|
|
||||||
// vendors async chunk, remaining asynchronously used node modules as single chunk file
|
|
||||||
test: /[\\/]node_modules[\\/]/,
|
|
||||||
name: 'vendors.async',
|
|
||||||
chunks: 'async',
|
|
||||||
priority: 9,
|
|
||||||
reuseExistingChunk: true,
|
|
||||||
minSize: 10000, // use smaller minSize to avoid too much potential bundle bloat due to module duplication.
|
|
||||||
},
|
|
||||||
commonsAsync: {
|
|
||||||
// commons async chunk, remaining asynchronously used modules as single chunk file
|
|
||||||
name: 'commons.async',
|
|
||||||
minChunks: 2, // Minimum number of chunks that must share a module before splitting
|
|
||||||
chunks: 'async',
|
|
||||||
priority: 0,
|
|
||||||
reuseExistingChunk: true,
|
|
||||||
minSize: 10000, // use smaller minSize to avoid too much potential bundle bloat due to module duplication.
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
performance: { hints: false },
|
|
||||||
devServer: {
|
|
||||||
contentBase: outDir,
|
|
||||||
// serve index.html for all 404 (required for push-state)
|
|
||||||
historyApiFallback: true,
|
|
||||||
},
|
|
||||||
devtool: production ? 'nosources-source-map' : 'cheap-module-eval-source-map',
|
|
||||||
module: {
|
|
||||||
rules: [
|
|
||||||
// CSS required in JS/TS files should use the style-loader that auto-injects it into the website
|
|
||||||
// only when the issuer is a .js/.ts file, so the loaders are not applied inside html templates
|
|
||||||
{
|
|
||||||
test: /\.css$/i,
|
|
||||||
issuer: [{ not: [{ test: /\.html$/i }] }],
|
|
||||||
use: extractCss
|
|
||||||
? [
|
|
||||||
{
|
|
||||||
loader: MiniCssExtractPlugin.loader,
|
|
||||||
},
|
|
||||||
'css-loader',
|
|
||||||
]
|
|
||||||
: ['style-loader', ...cssRules],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
test: /\.css$/i,
|
|
||||||
issuer: [{ test: /\.html$/i }],
|
|
||||||
// CSS required in templates cannot be extracted safely
|
|
||||||
// because Aurelia would try to require it again in runtime
|
|
||||||
use: cssRules,
|
|
||||||
},
|
|
||||||
{ test: /\.html$/i, loader: 'html-loader' },
|
|
||||||
{
|
|
||||||
test: /\.js$/i,
|
|
||||||
loader: 'babel-loader',
|
|
||||||
exclude: nodeModulesDir,
|
|
||||||
options: coverage ? { sourceMap: 'inline', plugins: ['istanbul'] } : {},
|
|
||||||
},
|
|
||||||
// embed small images and fonts as Data Urls and larger ones as files:
|
|
||||||
{
|
|
||||||
test: /\.(png|gif|jpg|cur)$/i,
|
|
||||||
loader: 'url-loader',
|
|
||||||
options: { limit: 8192 },
|
|
||||||
},
|
|
||||||
{
|
|
||||||
test: /\.woff2(\?v=[0-9]\.[0-9]\.[0-9])?$/i,
|
|
||||||
loader: 'url-loader',
|
|
||||||
options: { limit: 10000, mimetype: 'application/font-woff2' },
|
|
||||||
},
|
|
||||||
{
|
|
||||||
test: /\.woff(\?v=[0-9]\.[0-9]\.[0-9])?$/i,
|
|
||||||
loader: 'url-loader',
|
|
||||||
options: { limit: 10000, mimetype: 'application/font-woff' },
|
|
||||||
},
|
|
||||||
// load these fonts normally, as files:
|
|
||||||
{
|
|
||||||
test: /\.(ttf|eot|svg|otf)(\?v=[0-9]\.[0-9]\.[0-9])?$/i,
|
|
||||||
loader: 'file-loader',
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
plugins: [
|
|
||||||
...when(!karma, new DuplicatePackageCheckerPlugin()),
|
|
||||||
new AureliaPlugin(),
|
|
||||||
new ProvidePlugin({
|
|
||||||
Promise: ['promise-polyfill', 'default'],
|
|
||||||
}),
|
|
||||||
new ModuleDependenciesPlugin({
|
|
||||||
'aurelia-testing': ['./compile-spy', './view-spy'],
|
|
||||||
}),
|
|
||||||
new HtmlWebpackPlugin({
|
|
||||||
template: 'index.ejs',
|
|
||||||
metadata: {
|
|
||||||
// available in index.ejs //
|
|
||||||
title,
|
|
||||||
server,
|
|
||||||
baseUrl,
|
|
||||||
},
|
|
||||||
}),
|
|
||||||
// ref: https://webpack.js.org/plugins/mini-css-extract-plugin/
|
|
||||||
...when(
|
|
||||||
extractCss,
|
|
||||||
new MiniCssExtractPlugin({
|
|
||||||
// updated to match the naming conventions for the js files
|
|
||||||
filename: production
|
|
||||||
? 'css/[name].[contenthash].bundle.css'
|
|
||||||
: 'css/[name].[hash].bundle.css',
|
|
||||||
chunkFilename: production
|
|
||||||
? 'css/[name].[contenthash].chunk.css'
|
|
||||||
: 'css/[name].[hash].chunk.css',
|
|
||||||
})
|
|
||||||
),
|
|
||||||
...when(
|
|
||||||
production || server,
|
|
||||||
new CopyWebpackPlugin([{ from: 'static', to: outDir, ignore: ['.*'] }])
|
|
||||||
), // ignore dot (hidden) files
|
|
||||||
...when(analyze, new BundleAnalyzerPlugin()),
|
|
||||||
],
|
|
||||||
});
|
|
||||||
@@ -6,7 +6,7 @@ This directory is a brief example of a [Brunch](https://brunch.io/) site that ca
|
|||||||
|
|
||||||
Deploy your own Brunch project with ZEIT Now.
|
Deploy your own Brunch project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/brunch)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/brunch)
|
||||||
|
|
||||||
_Live Example: https://brunch.now-examples.now.sh_
|
_Live Example: https://brunch.now-examples.now.sh_
|
||||||
|
|
||||||
|
|||||||
115
examples/brunch/app/assets/brunch-napkin.svg
Normal file
115
examples/brunch/app/assets/brunch-napkin.svg
Normal file
@@ -0,0 +1,115 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 17.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||||
|
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
||||||
|
width="256px" height="256px" viewBox="0 0 256 256" enable-background="new 0 0 256 256" xml:space="preserve">
|
||||||
|
<rect x="65" y="68" fill="#7C7C7C" width="127" height="124"/>
|
||||||
|
<rect x="83.392" y="22.163" transform="matrix(-0.7071 0.7071 -0.7071 -0.7071 266.9294 23.9747)" fill="#86AD8A" width="90.215" height="90.215"/>
|
||||||
|
<path fill="#FFFFFF" d="M117.601,167.637c3.788-11.191,5.795-45.647,4.728-62.795c-0.128-2.057-0.333-4.445-0.692-6.351
|
||||||
|
c-0.112-0.607-0.244-1.168-0.391-1.651c0-6.672,0-62.892,0-67.02c0-5.717,5.242-8.419,10.166,4.128
|
||||||
|
c4.925,12.547,3.495,57.175,3.495,60.348c0,0.673-0.611,1.469-1.57,2.25c-0.383,0.247-0.73,0.499-1.051,0.754
|
||||||
|
c-2.949,2.366-3.379,5.095-3.533,7.542c-1.067,17.148-1.554,51.604,2.234,62.795c4.438,13.112-4.004,14.759-6.691,14.759
|
||||||
|
C121.605,182.395,113.163,180.748,117.601,167.637z"/>
|
||||||
|
<path fill="#FFFFFF" d="M103.019,47.413c-0.472,0.049-1.062,9.387-1.257,16.131c-0.238,8.194-0.607,15.482-2.908,15.482
|
||||||
|
c-1.728,0-2.8-2.853-2.517-10.094c0.407-10.427,0.395-21.519-0.219-21.519c-0.774,0-4.358,22.999-4.358,31.09
|
||||||
|
c0,5.803,2.487,11.269,5.603,14.115c0.01,0.008,0.019,0.019,0.033,0.027c0.093,0.081,0.191,0.166,0.278,0.247
|
||||||
|
c0.005,0.004,0.01,0.004,0.01,0.008c2.252,2.053,2.819,4.283,2.971,6.32c1.286,17.143-1.128,59.614-5.678,70.804
|
||||||
|
c-5.33,13.108,4.811,14.759,8.042,14.759c3.227,0,13.368-1.651,8.037-14.759c-4.55-11.191-6.96-53.661-5.678-70.804
|
||||||
|
c0.153-2.037,0.719-4.267,2.971-6.32c0-0.004,0.005-0.004,0.01-0.008c0.088-0.081,0.185-0.166,0.278-0.247
|
||||||
|
c0.014-0.008,0.023-0.019,0.033-0.027c3.116-2.845,5.764-8.314,5.604-14.115c-0.635-23.017-3.263-31.09-4.037-31.09
|
||||||
|
c-0.614,0-0.613,12.286-0.438,21.024c0.143,7.158-0.471,10.383-2.49,10.383c-1.923,0-2.504-6.972-2.748-15.368
|
||||||
|
c-0.196-6.762-0.804-16.039-1.54-16.039"/>
|
||||||
|
<path fill="#FFFFFF" d="M154.075,179.591c-2.546,0-10.532-1.562-6.332-13.967c3.585-10.59,5.483-50.779,4.474-67.007
|
||||||
|
c-0.051-0.826-0.256-1.664-0.413-2.55c-0.443-2.504-3.543-4.555-5.338-6.356c-3.486-3.498-5.725-9.38-5.725-16.013
|
||||||
|
c0-10.77,5.97-24.4,13.334-24.4c7.364,0,13.334,13.63,13.334,24.4c0,6.633-2.24,12.515-5.725,16.013
|
||||||
|
c-1.795,1.801-4.895,3.852-5.338,6.356c-0.157,0.886-0.361,1.724-0.413,2.55c-1.01,16.227,0.889,56.416,4.474,67.007
|
||||||
|
C164.607,178.03,156.621,179.591,154.075,179.591z"/>
|
||||||
|
<polyline fill="#CECCAE" points="65,68 65,192 192,192 "/>
|
||||||
|
<polygon fill="#3F894A" points="65,191.835 65,253 192,253 192,191.835 192,66.938 "/>
|
||||||
|
<g>
|
||||||
|
<g>
|
||||||
|
|
||||||
|
<line fill="none" stroke="#FFFFFF" stroke-width="0.5" stroke-miterlimit="10" x1="191.658" y1="82.55" x2="190.946" y2="83.253"/>
|
||||||
|
|
||||||
|
<line fill="none" stroke="#FFFFFF" stroke-width="0.5" stroke-miterlimit="10" stroke-dasharray="2.02,2.02" x1="189.509" y1="84.672" x2="66.629" y2="206.035"/>
|
||||||
|
|
||||||
|
<line fill="none" stroke="#FFFFFF" stroke-width="0.5" stroke-miterlimit="10" x1="65.91" y1="206.745" x2="65.199" y2="207.448"/>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path fill="#FFFFFF" d="M85.353,211.117h6.328c0.827,0,1.665,0.067,2.513,0.201c0.848,0.135,1.608,0.414,2.28,0.838
|
||||||
|
c0.672,0.424,1.22,1.014,1.644,1.768c0.424,0.756,0.636,1.753,0.636,2.994c0,1.116-0.331,2.089-0.993,2.916
|
||||||
|
c-0.662,0.827-1.644,1.376-2.947,1.645v0.062c0.724,0.062,1.385,0.232,1.985,0.512c0.6,0.279,1.117,0.651,1.551,1.117
|
||||||
|
c0.434,0.465,0.77,1.019,1.008,1.659c0.238,0.642,0.357,1.345,0.357,2.109c0,1.262-0.243,2.291-0.729,3.087
|
||||||
|
c-0.486,0.797-1.097,1.422-1.83,1.877c-0.734,0.455-1.531,0.766-2.389,0.931c-0.858,0.166-1.66,0.248-2.404,0.248h-7.011V211.117z
|
||||||
|
M87.4,220.609h4.25c1.055,0,1.913-0.129,2.575-0.388c0.662-0.259,1.179-0.574,1.551-0.946c0.373-0.372,0.621-0.771,0.745-1.194
|
||||||
|
s0.186-0.812,0.186-1.163c0-0.765-0.129-1.401-0.388-1.908c-0.259-0.506-0.605-0.909-1.039-1.21
|
||||||
|
c-0.435-0.299-0.941-0.512-1.52-0.636c-0.579-0.124-1.189-0.186-1.831-0.186H87.4V220.609z M87.4,231.219h4.684
|
||||||
|
c1.199,0,2.166-0.145,2.9-0.435c0.734-0.289,1.298-0.651,1.691-1.085c0.393-0.435,0.656-0.895,0.791-1.381
|
||||||
|
c0.134-0.485,0.202-0.926,0.202-1.318c0-0.807-0.155-1.499-0.465-2.078s-0.713-1.05-1.21-1.412c-0.496-0.361-1.06-0.625-1.69-0.791
|
||||||
|
c-0.631-0.165-1.267-0.248-1.908-0.248H87.4V231.219z"/>
|
||||||
|
<path fill="#FFFFFF" d="M103.73,222.781c0-0.269-0.011-0.595-0.031-0.978c-0.021-0.383-0.036-0.771-0.046-1.163
|
||||||
|
c-0.011-0.393-0.026-0.76-0.047-1.102c-0.021-0.341-0.031-0.604-0.031-0.791h1.861c0.021,0.538,0.036,1.055,0.046,1.551
|
||||||
|
c0.01,0.497,0.036,0.817,0.078,0.962c0.476-0.848,1.086-1.54,1.83-2.078c0.745-0.538,1.654-0.807,2.73-0.807
|
||||||
|
c0.186,0,0.367,0.016,0.543,0.047c0.175,0.03,0.357,0.067,0.543,0.108l-0.217,1.83c-0.248-0.082-0.486-0.124-0.713-0.124
|
||||||
|
c-0.807,0-1.504,0.129-2.094,0.388c-0.589,0.259-1.075,0.615-1.458,1.07s-0.667,0.987-0.853,1.598s-0.279,1.267-0.279,1.97v7.817
|
||||||
|
h-1.861V222.781z"/>
|
||||||
|
<path fill="#FFFFFF" d="M126,229.047c0,0.27,0.01,0.595,0.031,0.978c0.021,0.383,0.036,0.771,0.046,1.163
|
||||||
|
c0.01,0.394,0.026,0.761,0.047,1.102c0.02,0.341,0.031,0.604,0.031,0.791h-1.861c-0.021-0.537-0.036-1.055-0.046-1.551
|
||||||
|
c-0.011-0.497-0.036-0.817-0.078-0.962h-0.093c-0.373,0.786-0.993,1.463-1.861,2.032c-0.869,0.568-1.882,0.853-3.04,0.853
|
||||||
|
c-1.117,0-2.032-0.176-2.746-0.527s-1.272-0.812-1.675-1.38c-0.403-0.569-0.678-1.226-0.822-1.971
|
||||||
|
c-0.145-0.744-0.217-1.509-0.217-2.295v-8.531h1.861v8.438c0,0.58,0.051,1.144,0.155,1.691s0.284,1.039,0.543,1.474
|
||||||
|
c0.258,0.434,0.621,0.78,1.086,1.039s1.07,0.388,1.815,0.388c0.682,0,1.329-0.119,1.938-0.356c0.61-0.238,1.137-0.6,1.582-1.086
|
||||||
|
s0.796-1.097,1.055-1.83c0.258-0.734,0.388-1.598,0.388-2.591v-7.166H126V229.047z"/>
|
||||||
|
<path fill="#FFFFFF" d="M130.584,222.781c0-0.269-0.01-0.595-0.029-0.978c-0.021-0.383-0.037-0.771-0.047-1.163
|
||||||
|
c-0.012-0.393-0.027-0.76-0.047-1.102c-0.021-0.341-0.031-0.604-0.031-0.791h1.861c0.02,0.538,0.035,1.055,0.047,1.551
|
||||||
|
c0.01,0.497,0.035,0.817,0.076,0.962h0.094c0.373-0.785,0.992-1.463,1.861-2.032c0.869-0.568,1.883-0.853,3.041-0.853
|
||||||
|
c1.115,0,2.025,0.176,2.729,0.527s1.258,0.812,1.66,1.381c0.404,0.568,0.684,1.225,0.838,1.97c0.154,0.744,0.232,1.51,0.232,2.295
|
||||||
|
v8.531h-1.861v-8.438c0-0.579-0.051-1.143-0.154-1.691c-0.104-0.547-0.285-1.039-0.543-1.473c-0.26-0.435-0.621-0.781-1.086-1.04
|
||||||
|
c-0.465-0.258-1.07-0.388-1.814-0.388c-0.684,0-1.33,0.119-1.939,0.357c-0.609,0.237-1.137,0.6-1.582,1.085
|
||||||
|
c-0.445,0.486-0.797,1.097-1.055,1.831c-0.26,0.734-0.389,1.598-0.389,2.59v7.166h-1.861V222.781z"/>
|
||||||
|
<path fill="#FFFFFF" d="M159.28,230.971c-0.703,0.849-1.5,1.474-2.389,1.877c-0.89,0.403-1.852,0.604-2.885,0.604
|
||||||
|
c-1.097,0-2.11-0.186-3.041-0.559c-0.931-0.372-1.727-0.894-2.389-1.566c-0.662-0.672-1.179-1.468-1.551-2.389
|
||||||
|
c-0.372-0.92-0.559-1.928-0.559-3.024c0-1.096,0.187-2.104,0.559-3.024s0.889-1.717,1.551-2.389s1.458-1.194,2.389-1.566
|
||||||
|
c0.931-0.373,1.944-0.559,3.041-0.559c1.055,0,2.031,0.217,2.931,0.651c0.9,0.435,1.701,1.045,2.404,1.83l-1.489,1.117
|
||||||
|
c-0.537-0.6-1.127-1.07-1.768-1.412c-0.642-0.341-1.334-0.512-2.078-0.512c-0.869,0-1.655,0.155-2.358,0.466
|
||||||
|
c-0.703,0.31-1.303,0.729-1.799,1.256s-0.874,1.148-1.133,1.861c-0.259,0.714-0.388,1.474-0.388,2.28s0.129,1.566,0.388,2.28
|
||||||
|
c0.259,0.713,0.637,1.334,1.133,1.861s1.096,0.946,1.799,1.256c0.703,0.311,1.489,0.466,2.358,0.466
|
||||||
|
c0.785,0,1.504-0.181,2.155-0.543c0.651-0.361,1.215-0.843,1.69-1.442L159.28,230.971z"/>
|
||||||
|
<path fill="#FFFFFF" d="M161.925,209.628h1.861v11.633h0.062c0.372-0.785,0.992-1.463,1.861-2.032
|
||||||
|
c0.868-0.568,1.882-0.853,3.04-0.853c1.116,0,2.026,0.176,2.729,0.527s1.257,0.812,1.66,1.381c0.403,0.568,0.683,1.225,0.837,1.97
|
||||||
|
c0.155,0.744,0.233,1.51,0.233,2.295v8.531h-1.861v-8.438c0-0.579-0.052-1.143-0.155-1.691c-0.104-0.547-0.285-1.039-0.543-1.473
|
||||||
|
c-0.259-0.435-0.62-0.781-1.086-1.04c-0.465-0.258-1.07-0.388-1.814-0.388c-0.683,0-1.329,0.119-1.939,0.357
|
||||||
|
c-0.609,0.237-1.137,0.6-1.582,1.085c-0.444,0.486-0.796,1.097-1.055,1.831s-0.388,1.598-0.388,2.59v7.166h-1.861V209.628z"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 8.1 KiB |
@@ -10,7 +10,8 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="brunch">
|
<div class="brunch">
|
||||||
<a href="http://brunch.io"><img src="http://brunch.io/images/logo.png" alt="Brunch"></a>
|
<img src="/brunch-napkin.svg" alt="Brunch">
|
||||||
<p>Bon Appétit.</p>
|
<h4>Bon Appétit.</h4>
|
||||||
|
<h6>A <a href="http://brunch.io" target="_blank">Brunch</a> website deployed on <a href="https://zeit.co" target="_blank">ZEIT Now</a></h6>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
@@ -1,6 +1,21 @@
|
|||||||
|
html, body {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
display: flex;
|
||||||
|
margin: 0;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
.brunch {
|
.brunch {
|
||||||
font-family: -apple-system, Sans-Serif;
|
font-family: -apple-system, Sans-Serif;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: 24pt;
|
font-size: 24pt;
|
||||||
color: #3f894a;
|
color: #3f894a;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: inherit;
|
||||||
|
}
|
||||||
|
|||||||
5
examples/charge/.gitignore
vendored
5
examples/charge/.gitignore
vendored
@@ -1,5 +0,0 @@
|
|||||||
tmp
|
|
||||||
target
|
|
||||||
node_modules
|
|
||||||
.env
|
|
||||||
.env.build
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
README.md
|
|
||||||
yarn.lock
|
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
# Charge.js Example
|
|
||||||
|
|
||||||
This directory is a brief example of a [Charge.js](https://charge.js.org/) site that can be deployed with ZEIT Now and zero configuration.
|
|
||||||
|
|
||||||
## Deploy Your Own
|
|
||||||
|
|
||||||
Deploy your own Charge.js project with ZEIT Now.
|
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/charge)
|
|
||||||
|
|
||||||
_Live Example: https://charge.now-examples.now.sh_
|
|
||||||
|
|
||||||
### How We Created This Example
|
|
||||||
|
|
||||||
To get started with Charge.js, you can use [Now CLI](https://zeit.co/download) to initialize the project:
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now init charge
|
|
||||||
```
|
|
||||||
|
|
||||||
### Deploying From Your Terminal
|
|
||||||
|
|
||||||
You can deploy your new Charge.js project with a single command from your terminal using [Now CLI](https://zeit.co/download):
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now
|
|
||||||
```
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "charge-example",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"scripts": {
|
|
||||||
"start": "charge serve source",
|
|
||||||
"dev": "charge serve source --port $PORT",
|
|
||||||
"build": "charge build source public"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@static/charge": "^1.5.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
import About from './pages/about.html.mdx';
|
|
||||||
|
|
||||||
export default () => {
|
|
||||||
return (
|
|
||||||
<>
|
|
||||||
<h1>Welcome to my new Charge site!</h1>
|
|
||||||
<About />
|
|
||||||
</>
|
|
||||||
);
|
|
||||||
};
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
export default function Layout({ children }) {
|
|
||||||
return children;
|
|
||||||
}
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
import Layout from '../layout.html.jsx';
|
|
||||||
|
|
||||||
Everything between the import and export in the source is **just markdown** using [MDX](https://mdxjs.com/)!
|
|
||||||
|
|
||||||
export default ({ children }) => <Layout>{children}</Layout>;
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||

|

|
||||||
|
|
||||||
# React Example
|
# React Example
|
||||||
|
|
||||||
@@ -8,7 +8,7 @@ This directory is a brief example of a [React](https://reactjs.org/) app with [S
|
|||||||
|
|
||||||
Deploy your own React project, along with Serverless Functions, with ZEIT Now.
|
Deploy your own React project, along with Serverless Functions, with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/create-react-app-functions)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/create-react-app-functions)
|
||||||
|
|
||||||
_Live Example: https://create-react-app.now-examples.now.sh/_
|
_Live Example: https://create-react-app.now-examples.now.sh/_
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ This directory is a brief example of using a Custom Build script that can be dep
|
|||||||
|
|
||||||
Deploy your own Custom Built project with ZEIT Now.
|
Deploy your own Custom Built project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/custom-build)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/custom-build)
|
||||||
|
|
||||||
_Live Example: https://custom-build.now-examples.now.sh_
|
_Live Example: https://custom-build.now-examples.now.sh_
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||

|

|
||||||
|
|
||||||
# Docusaurus Example
|
# Docusaurus Example
|
||||||
|
|
||||||
@@ -8,7 +8,7 @@ This directory is a brief example of a [Docusaurus](https://docusaurus.io/) site
|
|||||||
|
|
||||||
Deploy your own Docusaurus project with ZEIT Now.
|
Deploy your own Docusaurus project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/docusaurus)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/docusaurus)
|
||||||
|
|
||||||
_Live Example: https://docusaurus.now-examples.now.sh_
|
_Live Example: https://docusaurus.now-examples.now.sh_
|
||||||
|
|
||||||
|
|||||||
4
examples/docz/.gitignore
vendored
4
examples/docz/.gitignore
vendored
@@ -1,4 +0,0 @@
|
|||||||
node_modules
|
|
||||||
.env
|
|
||||||
.env.build
|
|
||||||
.docz
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
README.md
|
|
||||||
yarn.lock
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
# Docz Example
|
|
||||||
|
|
||||||
This directory is a brief example of a [Docz](https://www.docz.site/) site that can be deployed with ZEIT Now and zero configuration.
|
|
||||||
|
|
||||||
## Deploy Your Own
|
|
||||||
|
|
||||||
Deploy your own Docz project with ZEIT Now.
|
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/docz)
|
|
||||||
|
|
||||||
_Live Example: https://docz.now-examples.now.sh_
|
|
||||||
|
|
||||||
### How We Created This Example
|
|
||||||
|
|
||||||
To get started with Docz for deployment with ZEIT Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project:
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now init docz
|
|
||||||
```
|
|
||||||
|
|
||||||
> The only change made is to add `dest: '/public'` to the `doczrc.js` file.
|
|
||||||
|
|
||||||
### Deploying From Your Terminal
|
|
||||||
|
|
||||||
You can deploy your new Docz project with a single command from your terminal using [Now CLI](https://zeit.co/download):
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now
|
|
||||||
```
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
export default {
|
|
||||||
dest: '/public',
|
|
||||||
public: '/pub',
|
|
||||||
};
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
---
|
|
||||||
name: Hello world
|
|
||||||
route: /
|
|
||||||
---
|
|
||||||
|
|
||||||
# Hello world!
|
|
||||||
|
|
||||||
I'm a documentation page, using MDX, created using [docz](https://docz.site) and deployed with [ZEIT Now](https://zeit.co/now)!
|
|
||||||
|
|
||||||
You can learn how to deploy a docz project from [the now-examples GitHub repository](https://github.com/zeit/now/tree/master/examples/docz)!
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "my-docz-project",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"scripts": {
|
|
||||||
"dev": "docz dev --port=$PORT",
|
|
||||||
"build": "docz build"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"docz": "1.2.0",
|
|
||||||
"docz-theme-default": "1.2.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||

|

|
||||||
|
|
||||||
# Eleventy Example
|
# Eleventy Example
|
||||||
|
|
||||||
@@ -8,7 +8,7 @@ This directory is a brief example of a [Eleventy](https://www.11ty.io/) site tha
|
|||||||
|
|
||||||
Deploy your own Eleventy project with ZEIT Now.
|
Deploy your own Eleventy project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/eleventy)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/eleventy)
|
||||||
|
|
||||||
_Live Example: https://eleventy.now-examples.now.sh_
|
_Live Example: https://eleventy.now-examples.now.sh_
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||

|

|
||||||
|
|
||||||
# Ember Example
|
# Ember Example
|
||||||
|
|
||||||
@@ -8,7 +8,7 @@ This directory is a brief example of an [Ember](https://emberjs.com/) app that c
|
|||||||
|
|
||||||
Deploy your own Ember project with ZEIT Now.
|
Deploy your own Ember project with ZEIT Now.
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/ember)
|
[](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/ember)
|
||||||
|
|
||||||
_Live Example: https://ember.now-examples.now.sh_
|
_Live Example: https://ember.now-examples.now.sh_
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"presets": [ "@babel/preset-env" ],
|
|
||||||
"compact": false
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
{
|
|
||||||
"directory": "bower_components"
|
|
||||||
}
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
# Browsers that we support
|
|
||||||
last 2 versions
|
|
||||||
ie >= 9
|
|
||||||
ios >= 7
|
|
||||||
android >= 4.4
|
|
||||||
8
examples/foundation/.gitignore
vendored
8
examples/foundation/.gitignore
vendored
@@ -1,8 +0,0 @@
|
|||||||
.DS_Store
|
|
||||||
node_modules
|
|
||||||
npm-debug.log
|
|
||||||
bower_components
|
|
||||||
dist
|
|
||||||
*.swp
|
|
||||||
.cache
|
|
||||||
.idea
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
README.md
|
|
||||||
yarn.lock
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
# Changelog
|
|
||||||
|
|
||||||
## Version 1.0 (November 19, 2015)
|
|
||||||
|
|
||||||
Initial release.
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
# Foundation Example
|
|
||||||
|
|
||||||
This directory is a brief example of a [Foundation](https://foundation.zurb.com/) site that can be deployed with ZEIT Now and zero configuration.
|
|
||||||
|
|
||||||
## Deploy Your Own
|
|
||||||
|
|
||||||
Deploy your own Foundation project with ZEIT Now.
|
|
||||||
|
|
||||||
[](https://zeit.co/new/project?template=https://github.com/zeit/now/tree/master/examples/foundation)
|
|
||||||
|
|
||||||
_Live Example: https://foundation.now-examples.now.sh_
|
|
||||||
|
|
||||||
### How We Created This Example
|
|
||||||
|
|
||||||
To get started with Foundation for deployment with ZEIT Now, you can use the [Foundation CLI](https://foundation.zurb.com/sites/docs/installation.html) to initialize the project:
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ npx foundation new my-foundation-site
|
|
||||||
```
|
|
||||||
|
|
||||||
> The only change made is to amend the output directory in `config.yml` to `"public"`.
|
|
||||||
|
|
||||||
### Deploying From Your Terminal
|
|
||||||
|
|
||||||
You can deploy your new Foundation project with a single command from your terminal using [Now CLI](https://zeit.co/download):
|
|
||||||
|
|
||||||
```shell
|
|
||||||
$ now
|
|
||||||
```
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user