diff --git a/examples/assemble/.gitattributes b/examples/assemble/.gitattributes deleted file mode 100644 index 759c2c5af..000000000 --- a/examples/assemble/.gitattributes +++ /dev/null @@ -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 \ No newline at end of file diff --git a/examples/assemble/.gitignore b/examples/assemble/.gitignore deleted file mode 100644 index 8872b0f13..000000000 --- a/examples/assemble/.gitignore +++ /dev/null @@ -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 diff --git a/examples/assemble/.nowignore b/examples/assemble/.nowignore deleted file mode 100644 index 42061c01a..000000000 --- a/examples/assemble/.nowignore +++ /dev/null @@ -1 +0,0 @@ -README.md \ No newline at end of file diff --git a/examples/assemble/Gruntfile.js b/examples/assemble/Gruntfile.js deleted file mode 100644 index 6f39ced1f..000000000 --- a/examples/assemble/Gruntfile.js +++ /dev/null @@ -1,30 +0,0 @@ -/* - * 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']); -}; diff --git a/examples/assemble/README.md b/examples/assemble/README.md deleted file mode 100644 index d9db788c9..000000000 --- a/examples/assemble/README.md +++ /dev/null @@ -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. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/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 -``` diff --git a/examples/assemble/content/blog-post.md b/examples/assemble/content/blog-post.md deleted file mode 100644 index e18f7b2be..000000000 --- a/examples/assemble/content/blog-post.md +++ /dev/null @@ -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. diff --git a/examples/assemble/package.json b/examples/assemble/package.json deleted file mode 100644 index 7125e3662..000000000 --- a/examples/assemble/package.json +++ /dev/null @@ -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": [] -} diff --git a/examples/assemble/templates/about.hbs b/examples/assemble/templates/about.hbs deleted file mode 100644 index 9f1f0c7c1..000000000 --- a/examples/assemble/templates/about.hbs +++ /dev/null @@ -1,7 +0,0 @@ ---- -title: About -description: This is the about page. ---- -

{{description}}

- -{{> button }} \ No newline at end of file diff --git a/examples/assemble/templates/blog.hbs b/examples/assemble/templates/blog.hbs deleted file mode 100644 index 68adad8ac..000000000 --- a/examples/assemble/templates/blog.hbs +++ /dev/null @@ -1,5 +0,0 @@ ---- -title: Blog ---- - -{{md 'content/blog-post.md'}} \ No newline at end of file diff --git a/examples/assemble/templates/home.hbs b/examples/assemble/templates/home.hbs deleted file mode 100644 index 843bbe651..000000000 --- a/examples/assemble/templates/home.hbs +++ /dev/null @@ -1,7 +0,0 @@ ---- -title: Home -description: This is the home page. ---- -

{{description}}

- -{{> button }} \ No newline at end of file diff --git a/examples/assemble/templates/includes/button.hbs b/examples/assemble/templates/includes/button.hbs deleted file mode 100644 index e1e9bb1f8..000000000 --- a/examples/assemble/templates/includes/button.hbs +++ /dev/null @@ -1 +0,0 @@ -Star Assemble on GitHub! \ No newline at end of file diff --git a/examples/assemble/templates/includes/head.hbs b/examples/assemble/templates/includes/head.hbs deleted file mode 100644 index 5c6b3c2e2..000000000 --- a/examples/assemble/templates/includes/head.hbs +++ /dev/null @@ -1,4 +0,0 @@ - -{{title}} - - \ No newline at end of file diff --git a/examples/assemble/templates/layouts/default.hbs b/examples/assemble/templates/layouts/default.hbs deleted file mode 100644 index c54e25729..000000000 --- a/examples/assemble/templates/layouts/default.hbs +++ /dev/null @@ -1,11 +0,0 @@ - - - - {{> head }} - - -
- {{> body }} -
- - \ No newline at end of file diff --git a/examples/aurelia/.babelrc.js b/examples/aurelia/.babelrc.js deleted file mode 100644 index 949e017fd..000000000 --- a/examples/aurelia/.babelrc.js +++ /dev/null @@ -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, - }, - ], - ], - }; -}; diff --git a/examples/aurelia/.editorconfig b/examples/aurelia/.editorconfig deleted file mode 100644 index 26692da27..000000000 --- a/examples/aurelia/.editorconfig +++ /dev/null @@ -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 diff --git a/examples/aurelia/.gitignore b/examples/aurelia/.gitignore deleted file mode 100644 index 0fe184248..000000000 --- a/examples/aurelia/.gitignore +++ /dev/null @@ -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 diff --git a/examples/aurelia/.nowignore b/examples/aurelia/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/aurelia/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/aurelia/README.md b/examples/aurelia/README.md deleted file mode 100644 index cfea2aabe..000000000 --- a/examples/aurelia/README.md +++ /dev/null @@ -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. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/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 -``` diff --git a/examples/aurelia/aurelia_project/aurelia.json b/examples/aurelia/aurelia_project/aurelia.json deleted file mode 100644 index fe5eca91d..000000000 --- a/examples/aurelia/aurelia_project/aurelia.json +++ /dev/null @@ -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" -} diff --git a/examples/aurelia/aurelia_project/environments/dev.js b/examples/aurelia/aurelia_project/environments/dev.js deleted file mode 100644 index 584675d9c..000000000 --- a/examples/aurelia/aurelia_project/environments/dev.js +++ /dev/null @@ -1,4 +0,0 @@ -export default { - debug: true, - testing: true, -}; diff --git a/examples/aurelia/aurelia_project/environments/prod.js b/examples/aurelia/aurelia_project/environments/prod.js deleted file mode 100644 index 0f7e1d740..000000000 --- a/examples/aurelia/aurelia_project/environments/prod.js +++ /dev/null @@ -1,4 +0,0 @@ -export default { - debug: false, - testing: false, -}; diff --git a/examples/aurelia/aurelia_project/environments/stage.js b/examples/aurelia/aurelia_project/environments/stage.js deleted file mode 100644 index c36ad4393..000000000 --- a/examples/aurelia/aurelia_project/environments/stage.js +++ /dev/null @@ -1,4 +0,0 @@ -export default { - debug: true, - testing: false, -}; diff --git a/examples/aurelia/aurelia_project/generators/attribute.js b/examples/aurelia/aurelia_project/generators/attribute.js deleted file mode 100644 index f241cb7d4..000000000 --- a/examples/aurelia/aurelia_project/generators/attribute.js +++ /dev/null @@ -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) { - // - } -} -`; - } -} diff --git a/examples/aurelia/aurelia_project/generators/attribute.json b/examples/aurelia/aurelia_project/generators/attribute.json deleted file mode 100644 index ddf940c55..000000000 --- a/examples/aurelia/aurelia_project/generators/attribute.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "attribute", - "description": "Creates a custom attribute class and places it in the project resources." -} diff --git a/examples/aurelia/aurelia_project/generators/binding-behavior.js b/examples/aurelia/aurelia_project/generators/binding-behavior.js deleted file mode 100644 index 68b9f107d..000000000 --- a/examples/aurelia/aurelia_project/generators/binding-behavior.js +++ /dev/null @@ -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) { - // - } -} -`; - } -} diff --git a/examples/aurelia/aurelia_project/generators/binding-behavior.json b/examples/aurelia/aurelia_project/generators/binding-behavior.json deleted file mode 100644 index 60906a174..000000000 --- a/examples/aurelia/aurelia_project/generators/binding-behavior.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "binding-behavior", - "description": "Creates a binding behavior class and places it in the project resources." -} diff --git a/examples/aurelia/aurelia_project/generators/component.js b/examples/aurelia/aurelia_project/generators/component.js deleted file mode 100644 index 3835d4018..000000000 --- a/examples/aurelia/aurelia_project/generators/component.js +++ /dev/null @@ -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 ` -`; - } -} diff --git a/examples/aurelia/aurelia_project/generators/component.json b/examples/aurelia/aurelia_project/generators/component.json deleted file mode 100644 index 99452f631..000000000 --- a/examples/aurelia/aurelia_project/generators/component.json +++ /dev/null @@ -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)." -} diff --git a/examples/aurelia/aurelia_project/generators/element.js b/examples/aurelia/aurelia_project/generators/element.js deleted file mode 100644 index 930d31b3c..000000000 --- a/examples/aurelia/aurelia_project/generators/element.js +++ /dev/null @@ -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 ` -`; - } -} diff --git a/examples/aurelia/aurelia_project/generators/element.json b/examples/aurelia/aurelia_project/generators/element.json deleted file mode 100644 index 68d8c54e0..000000000 --- a/examples/aurelia/aurelia_project/generators/element.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "element", - "description": "Creates a custom element class and template, placing them in the project resources." -} diff --git a/examples/aurelia/aurelia_project/generators/generator.js b/examples/aurelia/aurelia_project/generators/generator.js deleted file mode 100644 index e95d1454a..000000000 --- a/examples/aurelia/aurelia_project/generators/generator.js +++ /dev/null @@ -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) { - // - } -} -\` - } -} -`; - } -} diff --git a/examples/aurelia/aurelia_project/generators/generator.json b/examples/aurelia/aurelia_project/generators/generator.json deleted file mode 100644 index be946a5a9..000000000 --- a/examples/aurelia/aurelia_project/generators/generator.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "generator", - "description": "Creates a generator class and places it in the project generators folder." -} diff --git a/examples/aurelia/aurelia_project/generators/task.js b/examples/aurelia/aurelia_project/generators/task.js deleted file mode 100644 index 93cc346ab..000000000 --- a/examples/aurelia/aurelia_project/generators/task.js +++ /dev/null @@ -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)); -} -`; - } -} diff --git a/examples/aurelia/aurelia_project/generators/task.json b/examples/aurelia/aurelia_project/generators/task.json deleted file mode 100644 index fd15bc626..000000000 --- a/examples/aurelia/aurelia_project/generators/task.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "task", - "description": "Creates a task and places it in the project tasks folder." -} diff --git a/examples/aurelia/aurelia_project/generators/value-converter.js b/examples/aurelia/aurelia_project/generators/value-converter.js deleted file mode 100644 index 9167bfdcf..000000000 --- a/examples/aurelia/aurelia_project/generators/value-converter.js +++ /dev/null @@ -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) { - // - } -} -`; - } -} diff --git a/examples/aurelia/aurelia_project/generators/value-converter.json b/examples/aurelia/aurelia_project/generators/value-converter.json deleted file mode 100644 index 11081226c..000000000 --- a/examples/aurelia/aurelia_project/generators/value-converter.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "value-converter", - "description": "Creates a value converter class and places it in the project resources." -} diff --git a/examples/aurelia/aurelia_project/tasks/build.js b/examples/aurelia/aurelia_project/tasks/build.js deleted file mode 100644 index 0d8cfeec9..000000000 --- a/examples/aurelia/aurelia_project/tasks/build.js +++ /dev/null @@ -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 }; diff --git a/examples/aurelia/aurelia_project/tasks/build.json b/examples/aurelia/aurelia_project/tasks/build.json deleted file mode 100644 index 27a093605..000000000 --- a/examples/aurelia/aurelia_project/tasks/build.json +++ /dev/null @@ -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" - } - ] -} diff --git a/examples/aurelia/aurelia_project/tasks/environment.js b/examples/aurelia/aurelia_project/tasks/environment.js deleted file mode 100644 index 270bb5715..000000000 --- a/examples/aurelia/aurelia_project/tasks/environment.js +++ /dev/null @@ -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; diff --git a/examples/aurelia/aurelia_project/tasks/jest.js b/examples/aurelia/aurelia_project/tasks/jest.js deleted file mode 100644 index fc3758832..000000000 --- a/examples/aurelia/aurelia_project/tasks/jest.js +++ /dev/null @@ -1 +0,0 @@ -export { default } from './test'; diff --git a/examples/aurelia/aurelia_project/tasks/jest.json b/examples/aurelia/aurelia_project/tasks/jest.json deleted file mode 100644 index 274d1a888..000000000 --- a/examples/aurelia/aurelia_project/tasks/jest.json +++ /dev/null @@ -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" - } - ] -} diff --git a/examples/aurelia/aurelia_project/tasks/run.js b/examples/aurelia/aurelia_project/tasks/run.js deleted file mode 100644 index e62529cbb..000000000 --- a/examples/aurelia/aurelia_project/tasks/run.js +++ /dev/null @@ -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 "" 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 }; diff --git a/examples/aurelia/aurelia_project/tasks/run.json b/examples/aurelia/aurelia_project/tasks/run.json deleted file mode 100644 index 99b409d69..000000000 --- a/examples/aurelia/aurelia_project/tasks/run.json +++ /dev/null @@ -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" - } - ] -} diff --git a/examples/aurelia/aurelia_project/tasks/test.js b/examples/aurelia/aurelia_project/tasks/test.js deleted file mode 100644 index c54879206..000000000 --- a/examples/aurelia/aurelia_project/tasks/test.js +++ /dev/null @@ -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(); - } - }); -}; diff --git a/examples/aurelia/aurelia_project/tasks/test.json b/examples/aurelia/aurelia_project/tasks/test.json deleted file mode 100644 index db2e88ad3..000000000 --- a/examples/aurelia/aurelia_project/tasks/test.json +++ /dev/null @@ -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" - } - ] -} diff --git a/examples/aurelia/favicon.ico b/examples/aurelia/favicon.ico deleted file mode 100644 index 330515e9c..000000000 Binary files a/examples/aurelia/favicon.ico and /dev/null differ diff --git a/examples/aurelia/index.ejs b/examples/aurelia/index.ejs deleted file mode 100644 index adf4c111b..000000000 --- a/examples/aurelia/index.ejs +++ /dev/null @@ -1,12 +0,0 @@ - - - - - <%- htmlWebpackPlugin.options.metadata.title %> - - - - - - - diff --git a/examples/aurelia/jsconfig.json b/examples/aurelia/jsconfig.json deleted file mode 100644 index 257bfbed2..000000000 --- a/examples/aurelia/jsconfig.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "compilerOptions": { - "target": "es2015", - "lib": ["es2017", "dom"], - "experimentalDecorators": true - }, - "exclude": ["node_modules", "dist"] -} diff --git a/examples/aurelia/package.json b/examples/aurelia/package.json deleted file mode 100644 index 626f9745f..000000000 --- a/examples/aurelia/package.json +++ /dev/null @@ -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$": "/node_modules/aurelia-binding" - }, - "modulePaths": [ - "/src", - "/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": [ - "/test/jest-pretest.js" - ], - "testEnvironment": "node", - "collectCoverage": true, - "collectCoverageFrom": [ - "src/**/*.js", - "!**/*.spec.js", - "!**/node_modules/**", - "!**/test/**" - ], - "coverageDirectory": "/test/coverage-jest", - "coverageReporters": [ - "json", - "lcov", - "text", - "html" - ] - } -} diff --git a/examples/aurelia/src/app.html b/examples/aurelia/src/app.html deleted file mode 100644 index dfa5fbf14..000000000 --- a/examples/aurelia/src/app.html +++ /dev/null @@ -1,3 +0,0 @@ - diff --git a/examples/aurelia/src/app.js b/examples/aurelia/src/app.js deleted file mode 100644 index 222bb6a41..000000000 --- a/examples/aurelia/src/app.js +++ /dev/null @@ -1,3 +0,0 @@ -export class App { - message = 'Hello World!'; -} diff --git a/examples/aurelia/src/main.js b/examples/aurelia/src/main.js deleted file mode 100644 index e30b4144b..000000000 --- a/examples/aurelia/src/main.js +++ /dev/null @@ -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'))); -} diff --git a/examples/aurelia/src/resources/index.js b/examples/aurelia/src/resources/index.js deleted file mode 100644 index 5e2bb3b55..000000000 --- a/examples/aurelia/src/resources/index.js +++ /dev/null @@ -1,3 +0,0 @@ -export function configure(config) { - //config.globalResources([]); -} diff --git a/examples/aurelia/static/favicon.ico b/examples/aurelia/static/favicon.ico deleted file mode 100644 index 330515e9c..000000000 Binary files a/examples/aurelia/static/favicon.ico and /dev/null differ diff --git a/examples/aurelia/test/jest-pretest.js b/examples/aurelia/test/jest-pretest.js deleted file mode 100644 index ed0f19f40..000000000 --- a/examples/aurelia/test/jest-pretest.js +++ /dev/null @@ -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(); diff --git a/examples/aurelia/test/unit/.eslintrc b/examples/aurelia/test/unit/.eslintrc deleted file mode 100644 index 92629674b..000000000 --- a/examples/aurelia/test/unit/.eslintrc +++ /dev/null @@ -1,5 +0,0 @@ -{ - "rules": { - "no-var": 0 - } -} diff --git a/examples/aurelia/test/unit/app.spec.js b/examples/aurelia/test/unit/app.spec.js deleted file mode 100644 index c97978204..000000000 --- a/examples/aurelia/test/unit/app.spec.js +++ /dev/null @@ -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( - '' - ); - }); - - 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(); - }); - }); -}); diff --git a/examples/aurelia/webpack.config.js b/examples/aurelia/webpack.config.js deleted file mode 100644 index fb28eec8a..000000000 --- a/examples/aurelia/webpack.config.js +++ /dev/null @@ -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()), - ], -}); diff --git a/examples/charge/.gitignore b/examples/charge/.gitignore deleted file mode 100644 index 7cf95f8b7..000000000 --- a/examples/charge/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -tmp -target -node_modules -.env -.env.build \ No newline at end of file diff --git a/examples/charge/.nowignore b/examples/charge/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/charge/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/charge/README.md b/examples/charge/README.md deleted file mode 100644 index d74384721..000000000 --- a/examples/charge/README.md +++ /dev/null @@ -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. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/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 -``` diff --git a/examples/charge/package.json b/examples/charge/package.json deleted file mode 100644 index 2f853952c..000000000 --- a/examples/charge/package.json +++ /dev/null @@ -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" - } -} diff --git a/examples/charge/source/index.html.jsx b/examples/charge/source/index.html.jsx deleted file mode 100644 index 1eb763810..000000000 --- a/examples/charge/source/index.html.jsx +++ /dev/null @@ -1,10 +0,0 @@ -import About from './pages/about.html.mdx'; - -export default () => { - return ( - <> -

Welcome to my new Charge site!

- - - ); -}; diff --git a/examples/charge/source/layout.html.jsx b/examples/charge/source/layout.html.jsx deleted file mode 100644 index 5c48460a5..000000000 --- a/examples/charge/source/layout.html.jsx +++ /dev/null @@ -1,3 +0,0 @@ -export default function Layout({ children }) { - return children; -} diff --git a/examples/charge/source/pages/about.html.mdx b/examples/charge/source/pages/about.html.mdx deleted file mode 100644 index cc195022c..000000000 --- a/examples/charge/source/pages/about.html.mdx +++ /dev/null @@ -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 }) => {children}; diff --git a/examples/docz/.gitignore b/examples/docz/.gitignore deleted file mode 100644 index 54fab24bc..000000000 --- a/examples/docz/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -node_modules -.env -.env.build -.docz \ No newline at end of file diff --git a/examples/docz/.nowignore b/examples/docz/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/docz/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/docz/README.md b/examples/docz/README.md deleted file mode 100644 index ea2c8a56e..000000000 --- a/examples/docz/README.md +++ /dev/null @@ -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. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/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 -``` diff --git a/examples/docz/doczrc.js b/examples/docz/doczrc.js deleted file mode 100644 index 66ac1e842..000000000 --- a/examples/docz/doczrc.js +++ /dev/null @@ -1,4 +0,0 @@ -export default { - dest: '/public', - public: '/pub', -}; diff --git a/examples/docz/hello-world.mdx b/examples/docz/hello-world.mdx deleted file mode 100644 index 860d3d660..000000000 --- a/examples/docz/hello-world.mdx +++ /dev/null @@ -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)! diff --git a/examples/docz/package.json b/examples/docz/package.json deleted file mode 100644 index b5b5843b6..000000000 --- a/examples/docz/package.json +++ /dev/null @@ -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" - } -} diff --git a/examples/foundation/.babelrc b/examples/foundation/.babelrc deleted file mode 100644 index fbb903aaa..000000000 --- a/examples/foundation/.babelrc +++ /dev/null @@ -1,4 +0,0 @@ -{ - "presets": [ "@babel/preset-env" ], - "compact": false -} diff --git a/examples/foundation/.bowerrc b/examples/foundation/.bowerrc deleted file mode 100644 index 69fad3580..000000000 --- a/examples/foundation/.bowerrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "directory": "bower_components" -} diff --git a/examples/foundation/.browserslistrc b/examples/foundation/.browserslistrc deleted file mode 100644 index 3739808dc..000000000 --- a/examples/foundation/.browserslistrc +++ /dev/null @@ -1,5 +0,0 @@ -# Browsers that we support -last 2 versions -ie >= 9 -ios >= 7 -android >= 4.4 diff --git a/examples/foundation/.gitignore b/examples/foundation/.gitignore deleted file mode 100644 index 1ebbffacf..000000000 --- a/examples/foundation/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -.DS_Store -node_modules -npm-debug.log -bower_components -dist -*.swp -.cache -.idea \ No newline at end of file diff --git a/examples/foundation/.nowignore b/examples/foundation/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/foundation/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/foundation/CHANGELOG.md b/examples/foundation/CHANGELOG.md deleted file mode 100644 index 381e1a1ad..000000000 --- a/examples/foundation/CHANGELOG.md +++ /dev/null @@ -1,5 +0,0 @@ -# Changelog - -## Version 1.0 (November 19, 2015) - -Initial release. diff --git a/examples/foundation/README.md b/examples/foundation/README.md deleted file mode 100644 index 5ed65ae68..000000000 --- a/examples/foundation/README.md +++ /dev/null @@ -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. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/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 -``` diff --git a/examples/foundation/config.yml b/examples/foundation/config.yml deleted file mode 100644 index ac5d480c1..000000000 --- a/examples/foundation/config.yml +++ /dev/null @@ -1,27 +0,0 @@ -# Your project's server will run on localhost:xxxx at this port -PORT: 8000 - -# UnCSS will use these settings -UNCSS_OPTIONS: - html: - # Search for used CSS classes in generated HTML files - - "dist/**/*.html" - ignore: - - !!js/regexp .foundation-mq - - !!js/regexp ^\.is-.* - -# Gulp will reference these paths when it copies files -PATHS: - # Path to dist folder - dist: "public" - # Paths to static assets that aren't images, CSS, or JavaScript - assets: - - "src/assets/**/*" - - "!src/assets/{img,js,scss}/**/*" - # Paths to Sass libraries, which can then be loaded with @import - sass: - - "node_modules/foundation-sites/scss" - - "node_modules/motion-ui/src" - # Paths to JavaScript entry points for webpack to bundle modules - entries: - - "src/assets/js/app.js" diff --git a/examples/foundation/gulpfile.babel.js b/examples/foundation/gulpfile.babel.js deleted file mode 100644 index f0d59487c..000000000 --- a/examples/foundation/gulpfile.babel.js +++ /dev/null @@ -1,211 +0,0 @@ -'use strict'; - -import plugins from 'gulp-load-plugins'; -import yargs from 'yargs'; -import browser from 'browser-sync'; -import gulp from 'gulp'; -import panini from 'panini'; -import rimraf from 'rimraf'; -import sherpa from 'style-sherpa'; -import yaml from 'js-yaml'; -import fs from 'fs'; -import webpackStream from 'webpack-stream'; -import webpack2 from 'webpack'; -import named from 'vinyl-named'; -import uncss from 'uncss'; -import autoprefixer from 'autoprefixer'; - -// Load all Gulp plugins into one variable -const $ = plugins(); - -// Check for --production flag -const PRODUCTION = !!yargs.argv.production; - -// Load settings from settings.yml -const { PORT, UNCSS_OPTIONS, PATHS } = loadConfig(); - -function loadConfig() { - let ymlFile = fs.readFileSync('config.yml', 'utf8'); - return yaml.load(ymlFile); -} - -// Build the "dist" folder by running all of the below tasks -// Sass must be run later so UnCSS can search for used classes in the others assets. -gulp.task( - 'build', - gulp.series( - clean, - gulp.parallel(pages, javascript, images, copy), - sass, - styleGuide - ) -); - -// Build the site, run the server, and watch for file changes -gulp.task('default', gulp.series('build', server, watch)); - -// Delete the "dist" folder -// This happens every time a build starts -function clean(done) { - rimraf(PATHS.dist, done); -} - -// Copy files out of the assets folder -// This task skips over the "img", "js", and "scss" folders, which are parsed separately -function copy() { - return gulp.src(PATHS.assets).pipe(gulp.dest(PATHS.dist + '/assets')); -} - -// Copy page templates into finished HTML files -function pages() { - return gulp - .src('src/pages/**/*.{html,hbs,handlebars}') - .pipe( - panini({ - root: 'src/pages/', - layouts: 'src/layouts/', - partials: 'src/partials/', - data: 'src/data/', - helpers: 'src/helpers/', - }) - ) - .pipe(gulp.dest(PATHS.dist)); -} - -// Load updated HTML templates and partials into Panini -function resetPages(done) { - panini.refresh(); - done(); -} - -// Generate a style guide from the Markdown content and HTML template in styleguide/ -function styleGuide(done) { - sherpa( - 'src/styleguide/index.md', - { - output: PATHS.dist + '/styleguide.html', - template: 'src/styleguide/template.html', - }, - done - ); -} - -// Compile Sass into CSS -// In production, the CSS is compressed -function sass() { - const postCssPlugins = [ - // Autoprefixer - autoprefixer(), - - // UnCSS - Uncomment to remove unused styles in production - // PRODUCTION && uncss.postcssPlugin(UNCSS_OPTIONS), - ].filter(Boolean); - - return gulp - .src('src/assets/scss/app.scss') - .pipe($.sourcemaps.init()) - .pipe( - $.sass({ - includePaths: PATHS.sass, - }).on('error', $.sass.logError) - ) - .pipe($.postcss(postCssPlugins)) - .pipe($.if(PRODUCTION, $.cleanCss({ compatibility: 'ie9' }))) - .pipe($.if(!PRODUCTION, $.sourcemaps.write())) - .pipe(gulp.dest(PATHS.dist + '/assets/css')) - .pipe(browser.reload({ stream: true })); -} - -let webpackConfig = { - mode: PRODUCTION ? 'production' : 'development', - module: { - rules: [ - { - test: /\.js$/, - use: { - loader: 'babel-loader', - options: { - presets: ['@babel/preset-env'], - compact: false, - }, - }, - }, - ], - }, - devtool: !PRODUCTION && 'source-map', -}; - -// Combine JavaScript into one file -// In production, the file is minified -function javascript() { - return gulp - .src(PATHS.entries) - .pipe(named()) - .pipe($.sourcemaps.init()) - .pipe(webpackStream(webpackConfig, webpack2)) - .pipe( - $.if( - PRODUCTION, - $.terser().on('error', e => { - console.log(e); - }) - ) - ) - .pipe($.if(!PRODUCTION, $.sourcemaps.write())) - .pipe(gulp.dest(PATHS.dist + '/assets/js')); -} - -// Copy images to the "dist" folder -// In production, the images are compressed -function images() { - return gulp - .src('src/assets/img/**/*') - .pipe( - $.if(PRODUCTION, $.imagemin([$.imagemin.jpegtran({ progressive: true })])) - ) - .pipe(gulp.dest(PATHS.dist + '/assets/img')); -} - -// Start a server with BrowserSync to preview the site in -function server(done) { - browser.init( - { - server: PATHS.dist, - port: PORT, - }, - done - ); -} - -// Reload the browser with BrowserSync -function reload(done) { - browser.reload(); - done(); -} - -// Watch for changes to static assets, pages, Sass, and JavaScript -function watch() { - gulp.watch(PATHS.assets, copy); - gulp - .watch('src/pages/**/*.html') - .on('all', gulp.series(pages, browser.reload)); - gulp - .watch('src/{layouts,partials}/**/*.html') - .on('all', gulp.series(resetPages, pages, browser.reload)); - gulp - .watch('src/data/**/*.{js,json,yml}') - .on('all', gulp.series(resetPages, pages, browser.reload)); - gulp - .watch('src/helpers/**/*.js') - .on('all', gulp.series(resetPages, pages, browser.reload)); - gulp.watch('src/assets/scss/**/*.scss').on('all', sass); - gulp - .watch('src/assets/js/**/*.js') - .on('all', gulp.series(javascript, browser.reload)); - gulp - .watch('src/assets/img/**/*') - .on('all', gulp.series(images, browser.reload)); - gulp - .watch('src/styleguide/**') - .on('all', gulp.series(styleGuide, browser.reload)); -} diff --git a/examples/foundation/package.json b/examples/foundation/package.json deleted file mode 100644 index 0bf7b628e..000000000 --- a/examples/foundation/package.json +++ /dev/null @@ -1,57 +0,0 @@ -{ - "name": "foundation-zurb-template", - "version": "1.0.0", - "description": "Official ZURB Template for Foundation for Sites.", - "main": "gulpfile.babel.js", - "scripts": { - "start": "gulp", - "build": "gulp build --production" - }, - "author": "ZURB ", - "license": "MIT", - "dependencies": { - "foundation-sites": "^6.5.1", - "jquery": "^3.2.1", - "motion-ui": "^2.0.3", - "what-input": "^5.1.2" - }, - "devDependencies": { - "@babel/core": "^7.1.2", - "@babel/preset-env": "^7.1.0", - "@babel/register": "^7.0.0", - "autoprefixer": "^9.1.5", - "babel-loader": "^8.0.4", - "browser-sync": "^2.10.0", - "gulp": "^4.0.0", - "gulp-babel": "^8.0.0", - "gulp-clean-css": "^3.3.1", - "gulp-cli": "^2.0.1", - "gulp-concat": "^2.5.2", - "gulp-extname": "^0.2.0", - "gulp-if": "^2.0.0", - "gulp-imagemin": "^4.1.0", - "gulp-load-plugins": "^1.1.0", - "gulp-postcss": "^8.0.0", - "gulp-sass": "^4.0.1", - "gulp-sourcemaps": "^2.6.4", - "gulp-terser": "^1.2.0", - "js-yaml": "^3.4.6", - "panini": "^1.3.0", - "rimraf": "^2.4.3", - "style-sherpa": "^1.0.0", - "uncss": "^0.16.2", - "vinyl-named": "^1.1.0", - "webpack": "^4.20.2", - "webpack-stream": "^5.1.1", - "yargs": "^12.0.2" - }, - "repository": { - "type": "git", - "url": "https://github.com/zurb/foundation-zurb-template.git" - }, - "bugs": { - "url": "https://github.com/zurb/foundation-sites/issues", - "email": "foundation@zurb.com" - }, - "private": true -} diff --git a/examples/foundation/src/assets/img/.gitkeep b/examples/foundation/src/assets/img/.gitkeep deleted file mode 100644 index e69de29bb..000000000 diff --git a/examples/foundation/src/assets/js/app.js b/examples/foundation/src/assets/js/app.js deleted file mode 100644 index e5f4058f6..000000000 --- a/examples/foundation/src/assets/js/app.js +++ /dev/null @@ -1,16 +0,0 @@ -import $ from 'jquery'; -import 'what-input'; - -// Foundation JS relies on a global variable. In ES6, all imports are hoisted -// to the top of the file so if we used `import` to import Foundation, -// it would execute earlier than we have assigned the global variable. -// This is why we have to use CommonJS require() here since it doesn't -// have the hoisting behavior. -window.jQuery = $; -require('foundation-sites'); - -// If you want to pick and choose which modules to include, comment out the above and uncomment -// the line below -//import './lib/foundation-explicit-pieces'; - -$(document).foundation(); diff --git a/examples/foundation/src/assets/js/lib/foundation-explicit-pieces.js b/examples/foundation/src/assets/js/lib/foundation-explicit-pieces.js deleted file mode 100644 index bbbe00246..000000000 --- a/examples/foundation/src/assets/js/lib/foundation-explicit-pieces.js +++ /dev/null @@ -1,83 +0,0 @@ -import $ from 'jquery'; - -import { Foundation } from 'foundation-sites/js/foundation.core'; -import * as CoreUtils from 'foundation-sites/js/foundation.core.utils'; -import { Box } from 'foundation-sites/js/foundation.util.box'; -import { onImagesLoaded } from 'foundation-sites/js/foundation.util.imageLoader'; -import { Keyboard } from 'foundation-sites/js/foundation.util.keyboard'; -import { MediaQuery } from 'foundation-sites/js/foundation.util.mediaQuery'; -import { Motion, Move } from 'foundation-sites/js/foundation.util.motion'; -import { Nest } from 'foundation-sites/js/foundation.util.nest'; -import { Timer } from 'foundation-sites/js/foundation.util.timer'; -import { Touch } from 'foundation-sites/js/foundation.util.touch'; -import { Triggers } from 'foundation-sites/js/foundation.util.triggers'; -import { Abide } from 'foundation-sites/js/foundation.abide'; -import { Accordion } from 'foundation-sites/js/foundation.accordion'; -import { AccordionMenu } from 'foundation-sites/js/foundation.accordionMenu'; -import { Drilldown } from 'foundation-sites/js/foundation.drilldown'; -import { Dropdown } from 'foundation-sites/js/foundation.dropdown'; -import { DropdownMenu } from 'foundation-sites/js/foundation.dropdownMenu'; -import { Equalizer } from 'foundation-sites/js/foundation.equalizer'; -import { Interchange } from 'foundation-sites/js/foundation.interchange'; -import { Magellan } from 'foundation-sites/js/foundation.magellan'; -import { OffCanvas } from 'foundation-sites/js/foundation.offcanvas'; -import { Orbit } from 'foundation-sites/js/foundation.orbit'; -import { ResponsiveMenu } from 'foundation-sites/js/foundation.responsiveMenu'; -import { ResponsiveToggle } from 'foundation-sites/js/foundation.responsiveToggle'; -import { Reveal } from 'foundation-sites/js/foundation.reveal'; -import { Slider } from 'foundation-sites/js/foundation.slider'; -import { SmoothScroll } from 'foundation-sites/js/foundation.smoothScroll'; -import { Sticky } from 'foundation-sites/js/foundation.sticky'; -import { Tabs } from 'foundation-sites/js/foundation.tabs'; -import { Toggler } from 'foundation-sites/js/foundation.toggler'; -import { Tooltip } from 'foundation-sites/js/foundation.tooltip'; -import { ResponsiveAccordionTabs } from 'foundation-sites/js/foundation.responsiveAccordionTabs'; - -Foundation.addToJquery($); - -// Add Foundation Utils to Foundation global namespace for backwards -// compatibility. -Foundation.rtl = CoreUtils.rtl; -Foundation.GetYoDigits = CoreUtils.GetYoDigits; -Foundation.transitionend = CoreUtils.transitionend; -Foundation.RegExpEscape = CoreUtils.RegExpEscape; -Foundation.onLoad = CoreUtils.onLoad; - -Foundation.Box = Box; -Foundation.onImagesLoaded = onImagesLoaded; -Foundation.Keyboard = Keyboard; -Foundation.MediaQuery = MediaQuery; -Foundation.Motion = Motion; -Foundation.Move = Move; -Foundation.Nest = Nest; -Foundation.Timer = Timer; - -// Touch and Triggers previously were almost purely sede effect driven, -// so no need to add it to Foundation, just init them. -Touch.init($); -Triggers.init($, Foundation); -MediaQuery._init(); - -Foundation.plugin(Abide, 'Abide'); -Foundation.plugin(Accordion, 'Accordion'); -Foundation.plugin(AccordionMenu, 'AccordionMenu'); -Foundation.plugin(Drilldown, 'Drilldown'); -Foundation.plugin(Dropdown, 'Dropdown'); -Foundation.plugin(DropdownMenu, 'DropdownMenu'); -Foundation.plugin(Equalizer, 'Equalizer'); -Foundation.plugin(Interchange, 'Interchange'); -Foundation.plugin(Magellan, 'Magellan'); -Foundation.plugin(OffCanvas, 'OffCanvas'); -Foundation.plugin(Orbit, 'Orbit'); -Foundation.plugin(ResponsiveMenu, 'ResponsiveMenu'); -Foundation.plugin(ResponsiveToggle, 'ResponsiveToggle'); -Foundation.plugin(Reveal, 'Reveal'); -Foundation.plugin(Slider, 'Slider'); -Foundation.plugin(SmoothScroll, 'SmoothScroll'); -Foundation.plugin(Sticky, 'Sticky'); -Foundation.plugin(Tabs, 'Tabs'); -Foundation.plugin(Toggler, 'Toggler'); -Foundation.plugin(Tooltip, 'Tooltip'); -Foundation.plugin(ResponsiveAccordionTabs, 'ResponsiveAccordionTabs'); - -export { Foundation }; diff --git a/examples/foundation/src/assets/scss/_settings.scss b/examples/foundation/src/assets/scss/_settings.scss deleted file mode 100644 index 4fd03e82a..000000000 --- a/examples/foundation/src/assets/scss/_settings.scss +++ /dev/null @@ -1,869 +0,0 @@ -// Foundation for Sites Settings -// ----------------------------- -// -// Table of Contents: -// -// 1. Global -// 2. Breakpoints -// 3. The Grid -// 4. Base Typography -// 5. Typography Helpers -// 6. Abide -// 7. Accordion -// 8. Accordion Menu -// 9. Badge -// 10. Breadcrumbs -// 11. Button -// 12. Button Group -// 13. Callout -// 14. Card -// 15. Close Button -// 16. Drilldown -// 17. Dropdown -// 18. Dropdown Menu -// 19. Flexbox Utilities -// 20. Forms -// 21. Label -// 22. Media Object -// 23. Menu -// 24. Meter -// 25. Off-canvas -// 26. Orbit -// 27. Pagination -// 28. Progress Bar -// 29. Prototype Arrow -// 30. Prototype Border-Box -// 31. Prototype Border-None -// 32. Prototype Bordered -// 33. Prototype Display -// 34. Prototype Font-Styling -// 35. Prototype List-Style-Type -// 36. Prototype Overflow -// 37. Prototype Position -// 38. Prototype Rounded -// 39. Prototype Separator -// 40. Prototype Shadow -// 41. Prototype Sizing -// 42. Prototype Spacing -// 43. Prototype Text-Decoration -// 44. Prototype Text-Transformation -// 45. Prototype Text-Utilities -// 46. Responsive Embed -// 47. Reveal -// 48. Slider -// 49. Switch -// 50. Table -// 51. Tabs -// 52. Thumbnail -// 53. Title Bar -// 54. Tooltip -// 55. Top Bar -// 56. Xy Grid - -@import 'util/util'; - -// 1. Global -// --------- - -$global-font-size: 100%; -$global-width: rem-calc(1200); -$global-lineheight: 1.5; -$foundation-palette: ( - primary: #1779ba, - secondary: #767676, - success: #3adb76, - warning: #ffae00, - alert: #cc4b37, -); -$light-gray: #e6e6e6; -$medium-gray: #cacaca; -$dark-gray: #8a8a8a; -$black: #0a0a0a; -$white: #fefefe; -$body-background: $white; -$body-font-color: $black; -$body-font-family: 'Helvetica Neue', Helvetica, Roboto, Arial, sans-serif; -$body-antialiased: true; -$global-margin: 1rem; -$global-padding: 1rem; -$global-position: 1rem; -$global-weight-normal: normal; -$global-weight-bold: bold; -$global-radius: 0; -$global-menu-padding: 0.7rem 1rem; -$global-menu-nested-margin: 1rem; -$global-text-direction: ltr; -$global-flexbox: true; -$global-prototype-breakpoints: false; -$global-button-cursor: auto; -$global-color-pick-contrast-tolerance: 0; -$print-transparent-backgrounds: true; - -@include add-foundation-colors; -$print-hrefs: true; - -// 2. Breakpoints -// -------------- - -$breakpoints: ( - small: 0, - medium: 640px, - large: 1024px, - xlarge: 1200px, - xxlarge: 1440px, -); -$print-breakpoint: large; -$breakpoint-classes: (small medium large); - -// 3. The Grid -// ----------- - -$grid-row-width: $global-width; -$grid-column-count: 12; -$grid-column-gutter: ( - small: 20px, - medium: 30px, -); -$grid-column-align-edge: true; -$grid-column-alias: 'columns'; -$block-grid-max: 8; - -// 4. Base Typography -// ------------------ - -$header-font-family: $body-font-family; -$header-font-weight: $global-weight-normal; -$header-font-style: normal; -$font-family-monospace: Consolas, 'Liberation Mono', Courier, monospace; -$header-color: inherit; -$header-lineheight: 1.4; -$header-margin-bottom: 0.5rem; -$header-styles: ( - small: ( - 'h1': ('font-size': 24), - 'h2': ('font-size': 20), - 'h3': ('font-size': 19), - 'h4': ('font-size': 18), - 'h5': ('font-size': 17), - 'h6': ('font-size': 16), - ), - medium: ( - 'h1': ('font-size': 48), - 'h2': ('font-size': 40), - 'h3': ('font-size': 31), - 'h4': ('font-size': 25), - 'h5': ('font-size': 20), - 'h6': ('font-size': 16), - ), -); -$header-text-rendering: optimizeLegibility; -$small-font-size: 80%; -$header-small-font-color: $medium-gray; -$paragraph-lineheight: 1.6; -$paragraph-margin-bottom: 1rem; -$paragraph-text-rendering: optimizeLegibility; -$code-color: $black; -$code-font-family: $font-family-monospace; -$code-font-weight: $global-weight-normal; -$code-background: $light-gray; -$code-border: 1px solid $medium-gray; -$code-padding: rem-calc(2 5 1); -$anchor-color: $primary-color; -$anchor-color-hover: scale-color($anchor-color, $lightness: -14%); -$anchor-text-decoration: none; -$anchor-text-decoration-hover: none; -$hr-width: $global-width; -$hr-border: 1px solid $medium-gray; -$hr-margin: rem-calc(20) auto; -$list-lineheight: $paragraph-lineheight; -$list-margin-bottom: $paragraph-margin-bottom; -$list-style-type: disc; -$list-style-position: outside; -$list-side-margin: 1.25rem; -$list-nested-side-margin: 1.25rem; -$defnlist-margin-bottom: 1rem; -$defnlist-term-weight: $global-weight-bold; -$defnlist-term-margin-bottom: 0.3rem; -$blockquote-color: $dark-gray; -$blockquote-padding: rem-calc(9 20 0 19); -$blockquote-border: 1px solid $medium-gray; -$cite-font-size: rem-calc(13); -$cite-color: $dark-gray; -$cite-pseudo-content: '\2014 \0020'; -$keystroke-font: $font-family-monospace; -$keystroke-color: $black; -$keystroke-background: $light-gray; -$keystroke-padding: rem-calc(2 4 0); -$keystroke-radius: $global-radius; -$abbr-underline: 1px dotted $black; - -// 5. Typography Helpers -// --------------------- - -$lead-font-size: $global-font-size * 1.25; -$lead-lineheight: 1.6; -$subheader-lineheight: 1.4; -$subheader-color: $dark-gray; -$subheader-font-weight: $global-weight-normal; -$subheader-margin-top: 0.2rem; -$subheader-margin-bottom: 0.5rem; -$stat-font-size: 2.5rem; - -// 6. Abide -// -------- - -$abide-inputs: true; -$abide-labels: true; -$input-background-invalid: get-color(alert); -$form-label-color-invalid: get-color(alert); -$input-error-color: get-color(alert); -$input-error-font-size: rem-calc(12); -$input-error-font-weight: $global-weight-bold; - -// 7. Accordion -// ------------ - -$accordion-background: $white; -$accordion-plusminus: true; -$accordion-title-font-size: rem-calc(12); -$accordion-item-color: $primary-color; -$accordion-item-background-hover: $light-gray; -$accordion-item-padding: 1.25rem 1rem; -$accordion-content-background: $white; -$accordion-content-border: 1px solid $light-gray; -$accordion-content-color: $body-font-color; -$accordion-content-padding: 1rem; - -// 8. Accordion Menu -// ----------------- - -$accordionmenu-padding: $global-menu-padding; -$accordionmenu-nested-margin: $global-menu-nested-margin; -$accordionmenu-submenu-padding: $accordionmenu-padding; -$accordionmenu-arrows: true; -$accordionmenu-arrow-color: $primary-color; -$accordionmenu-item-background: null; -$accordionmenu-border: null; -$accordionmenu-submenu-toggle-background: null; -$accordion-submenu-toggle-border: $accordionmenu-border; -$accordionmenu-submenu-toggle-width: 40px; -$accordionmenu-submenu-toggle-height: $accordionmenu-submenu-toggle-width; -$accordionmenu-arrow-size: 6px; - -// 9. Badge -// -------- - -$badge-background: $primary-color; -$badge-color: $white; -$badge-color-alt: $black; -$badge-palette: $foundation-palette; -$badge-padding: 0.3em; -$badge-minwidth: 2.1em; -$badge-font-size: 0.6rem; - -// 10. Breadcrumbs -// --------------- - -$breadcrumbs-margin: 0 0 $global-margin 0; -$breadcrumbs-item-font-size: rem-calc(11); -$breadcrumbs-item-color: $primary-color; -$breadcrumbs-item-color-current: $black; -$breadcrumbs-item-color-disabled: $medium-gray; -$breadcrumbs-item-margin: 0.75rem; -$breadcrumbs-item-uppercase: true; -$breadcrumbs-item-separator: true; -$breadcrumbs-item-separator-item: '/'; -$breadcrumbs-item-separator-item-rtl: '\\'; -$breadcrumbs-item-separator-color: $medium-gray; - -// 11. Button -// ---------- - -$button-font-family: inherit; -$button-padding: 0.85em 1em; -$button-margin: 0 0 $global-margin 0; -$button-fill: solid; -$button-background: $primary-color; -$button-background-hover: scale-color($button-background, $lightness: -15%); -$button-color: $white; -$button-color-alt: $black; -$button-radius: $global-radius; -$button-hollow-border-width: 1px; -$button-sizes: ( - tiny: 0.6rem, - small: 0.75rem, - default: 0.9rem, - large: 1.25rem, -); -$button-palette: $foundation-palette; -$button-opacity-disabled: 0.25; -$button-background-hover-lightness: -20%; -$button-hollow-hover-lightness: -50%; -$button-transition: background-color 0.25s ease-out, color 0.25s ease-out; -$button-responsive-expanded: false; - -// 12. Button Group -// ---------------- - -$buttongroup-margin: 1rem; -$buttongroup-spacing: 1px; -$buttongroup-child-selector: '.button'; -$buttongroup-expand-max: 6; -$buttongroup-radius-on-each: true; - -// 13. Callout -// ----------- - -$callout-background: $white; -$callout-background-fade: 85%; -$callout-border: 1px solid rgba($black, 0.25); -$callout-margin: 0 0 1rem 0; -$callout-padding: 1rem; -$callout-font-color: $body-font-color; -$callout-font-color-alt: $body-background; -$callout-radius: $global-radius; -$callout-link-tint: 30%; - -// 14. Card -// -------- - -$card-background: $white; -$card-font-color: $body-font-color; -$card-divider-background: $light-gray; -$card-border: 1px solid $light-gray; -$card-shadow: none; -$card-border-radius: $global-radius; -$card-padding: $global-padding; -$card-margin-bottom: $global-margin; - -// 15. Close Button -// ---------------- - -$closebutton-position: right top; -$closebutton-offset-horizontal: ( - small: 0.66rem, - medium: 1rem, -); -$closebutton-offset-vertical: ( - small: 0.33em, - medium: 0.5rem, -); -$closebutton-size: ( - small: 1.5em, - medium: 2em, -); -$closebutton-lineheight: 1; -$closebutton-color: $dark-gray; -$closebutton-color-hover: $black; - -// 16. Drilldown -// ------------- - -$drilldown-transition: transform 0.15s linear; -$drilldown-arrows: true; -$drilldown-padding: $global-menu-padding; -$drilldown-nested-margin: 0; -$drilldown-background: $white; -$drilldown-submenu-padding: $drilldown-padding; -$drilldown-submenu-background: $white; -$drilldown-arrow-color: $primary-color; -$drilldown-arrow-size: 6px; - -// 17. Dropdown -// ------------ - -$dropdown-padding: 1rem; -$dropdown-background: $body-background; -$dropdown-border: 1px solid $medium-gray; -$dropdown-font-size: 1rem; -$dropdown-width: 300px; -$dropdown-radius: $global-radius; -$dropdown-sizes: ( - tiny: 100px, - small: 200px, - large: 400px, -); - -// 18. Dropdown Menu -// ----------------- - -$dropdownmenu-arrows: true; -$dropdownmenu-arrow-color: $anchor-color; -$dropdownmenu-arrow-size: 6px; -$dropdownmenu-arrow-padding: 1.5rem; -$dropdownmenu-min-width: 200px; -$dropdownmenu-background: null; -$dropdownmenu-submenu-background: $white; -$dropdownmenu-padding: $global-menu-padding; -$dropdownmenu-nested-margin: 0; -$dropdownmenu-submenu-padding: $dropdownmenu-padding; -$dropdownmenu-border: 1px solid $medium-gray; -$dropdown-menu-item-color-active: get-color(primary); -$dropdown-menu-item-background-active: transparent; - -// 19. Flexbox Utilities -// --------------------- - -$flex-source-ordering-count: 6; -$flexbox-responsive-breakpoints: true; - -// 20. Forms -// --------- - -$fieldset-border: 1px solid $medium-gray; -$fieldset-padding: rem-calc(20); -$fieldset-margin: rem-calc(18 0); -$legend-padding: rem-calc(0 3); -$form-spacing: rem-calc(16); -$helptext-color: $black; -$helptext-font-size: rem-calc(13); -$helptext-font-style: italic; -$input-prefix-color: $black; -$input-prefix-background: $light-gray; -$input-prefix-border: 1px solid $medium-gray; -$input-prefix-padding: 1rem; -$form-label-color: $black; -$form-label-font-size: rem-calc(14); -$form-label-font-weight: $global-weight-normal; -$form-label-line-height: 1.8; -$select-background: $white; -$select-triangle-color: $dark-gray; -$select-radius: $global-radius; -$input-color: $black; -$input-placeholder-color: $medium-gray; -$input-font-family: inherit; -$input-font-size: rem-calc(16); -$input-font-weight: $global-weight-normal; -$input-line-height: $global-lineheight; -$input-background: $white; -$input-background-focus: $white; -$input-background-disabled: $light-gray; -$input-border: 1px solid $medium-gray; -$input-border-focus: 1px solid $dark-gray; -$input-padding: $form-spacing / 2; -$input-shadow: inset 0 1px 2px rgba($black, 0.1); -$input-shadow-focus: 0 0 5px $medium-gray; -$input-cursor-disabled: not-allowed; -$input-transition: box-shadow 0.5s, border-color 0.25s ease-in-out; -$input-number-spinners: true; -$input-radius: $global-radius; -$form-button-radius: $global-radius; - -// 21. Label -// --------- - -$label-background: $primary-color; -$label-color: $white; -$label-color-alt: $black; -$label-palette: $foundation-palette; -$label-font-size: 0.8rem; -$label-padding: 0.33333rem 0.5rem; -$label-radius: $global-radius; - -// 22. Media Object -// ---------------- - -$mediaobject-margin-bottom: $global-margin; -$mediaobject-section-padding: $global-padding; -$mediaobject-image-width-stacked: 100%; - -// 23. Menu -// -------- - -$menu-margin: 0; -$menu-nested-margin: $global-menu-nested-margin; -$menu-items-padding: $global-menu-padding; -$menu-simple-margin: 1rem; -$menu-item-color-active: $white; -$menu-item-background-active: get-color(primary); -$menu-icon-spacing: 0.25rem; -$menu-state-back-compat: true; -$menu-centered-back-compat: true; -$menu-icons-back-compat: true; - -// 24. Meter -// --------- - -$meter-height: 1rem; -$meter-radius: $global-radius; -$meter-background: $medium-gray; -$meter-fill-good: $success-color; -$meter-fill-medium: $warning-color; -$meter-fill-bad: $alert-color; - -// 25. Off-canvas -// -------------- - -$offcanvas-sizes: ( - small: 250px, -); -$offcanvas-vertical-sizes: ( - small: 250px, -); -$offcanvas-background: $light-gray; -$offcanvas-shadow: 0 0 10px rgba($black, 0.7); -$offcanvas-inner-shadow-size: 20px; -$offcanvas-inner-shadow-color: rgba($black, 0.25); -$offcanvas-overlay-zindex: 11; -$offcanvas-push-zindex: 12; -$offcanvas-overlap-zindex: 13; -$offcanvas-reveal-zindex: 12; -$offcanvas-transition-length: 0.5s; -$offcanvas-transition-timing: ease; -$offcanvas-fixed-reveal: true; -$offcanvas-exit-background: rgba($white, 0.25); -$maincontent-class: 'off-canvas-content'; - -// 26. Orbit -// --------- - -$orbit-bullet-background: $medium-gray; -$orbit-bullet-background-active: $dark-gray; -$orbit-bullet-diameter: 1.2rem; -$orbit-bullet-margin: 0.1rem; -$orbit-bullet-margin-top: 0.8rem; -$orbit-bullet-margin-bottom: 0.8rem; -$orbit-caption-background: rgba($black, 0.5); -$orbit-caption-padding: 1rem; -$orbit-control-background-hover: rgba($black, 0.5); -$orbit-control-padding: 1rem; -$orbit-control-zindex: 10; - -// 27. Pagination -// -------------- - -$pagination-font-size: rem-calc(14); -$pagination-margin-bottom: $global-margin; -$pagination-item-color: $black; -$pagination-item-padding: rem-calc(3 10); -$pagination-item-spacing: rem-calc(1); -$pagination-radius: $global-radius; -$pagination-item-background-hover: $light-gray; -$pagination-item-background-current: $primary-color; -$pagination-item-color-current: $white; -$pagination-item-color-disabled: $medium-gray; -$pagination-ellipsis-color: $black; -$pagination-mobile-items: false; -$pagination-mobile-current-item: false; -$pagination-arrows: true; - -// 28. Progress Bar -// ---------------- - -$progress-height: 1rem; -$progress-background: $medium-gray; -$progress-margin-bottom: $global-margin; -$progress-meter-background: $primary-color; -$progress-radius: $global-radius; - -// 29. Prototype Arrow -// ------------------- - -$prototype-arrow-directions: ( - down, - up, - right, - left -); -$prototype-arrow-size: 0.4375rem; -$prototype-arrow-color: $black; - -// 30. Prototype Border-Box -// ------------------------ - -$prototype-border-box-breakpoints: $global-prototype-breakpoints; - -// 31. Prototype Border-None -// ------------------------- - -$prototype-border-none-breakpoints: $global-prototype-breakpoints; - -// 32. Prototype Bordered -// ---------------------- - -$prototype-bordered-breakpoints: $global-prototype-breakpoints; -$prototype-border-width: rem-calc(1); -$prototype-border-type: solid; -$prototype-border-color: $medium-gray; - -// 33. Prototype Display -// --------------------- - -$prototype-display-breakpoints: $global-prototype-breakpoints; -$prototype-display: ( - inline, - inline-block, - block, - table, - table-cell -); - -// 34. Prototype Font-Styling -// -------------------------- - -$prototype-font-breakpoints: $global-prototype-breakpoints; -$prototype-wide-letter-spacing: rem-calc(4); -$prototype-font-normal: $global-weight-normal; -$prototype-font-bold: $global-weight-bold; - -// 35. Prototype List-Style-Type -// ----------------------------- - -$prototype-list-breakpoints: $global-prototype-breakpoints; -$prototype-style-type-unordered: ( - disc, - circle, - square -); -$prototype-style-type-ordered: ( - decimal, - lower-alpha, - lower-latin, - lower-roman, - upper-alpha, - upper-latin, - upper-roman -); - -// 36. Prototype Overflow -// ---------------------- - -$prototype-overflow-breakpoints: $global-prototype-breakpoints; -$prototype-overflow: ( - visible, - hidden, - scroll -); - -// 37. Prototype Position -// ---------------------- - -$prototype-position-breakpoints: $global-prototype-breakpoints; -$prototype-position: ( - static, - relative, - absolute, - fixed -); -$prototype-position-z-index: 975; - -// 38. Prototype Rounded -// --------------------- - -$prototype-rounded-breakpoints: $global-prototype-breakpoints; -$prototype-border-radius: rem-calc(3); - -// 39. Prototype Separator -// ----------------------- - -$prototype-separator-breakpoints: $global-prototype-breakpoints; -$prototype-separator-align: center; -$prototype-separator-height: rem-calc(2); -$prototype-separator-width: 3rem; -$prototype-separator-background: $primary-color; -$prototype-separator-margin-top: $global-margin; - -// 40. Prototype Shadow -// -------------------- - -$prototype-shadow-breakpoints: $global-prototype-breakpoints; -$prototype-box-shadow: 0 2px 5px 0 rgba(0,0,0,.16), - 0 2px 10px 0 rgba(0,0,0,.12); - -// 41. Prototype Sizing -// -------------------- - -$prototype-sizing-breakpoints: $global-prototype-breakpoints; -$prototype-sizing: ( - width, - height -); -$prototype-sizes: ( - 25: 25%, - 50: 50%, - 75: 75%, - 100: 100% -); - -// 42. Prototype Spacing -// --------------------- - -$prototype-spacing-breakpoints: $global-prototype-breakpoints; -$prototype-spacers-count: 3; - -// 43. Prototype Text-Decoration -// ----------------------------- - -$prototype-decoration-breakpoints: $global-prototype-breakpoints; -$prototype-text-decoration: ( - overline, - underline, - line-through, -); - -// 44. Prototype Text-Transformation -// --------------------------------- - -$prototype-transformation-breakpoints: $global-prototype-breakpoints; -$prototype-text-transformation: ( - lowercase, - uppercase, - capitalize -); - -// 45. Prototype Text-Utilities -// ---------------------------- - -$prototype-utilities-breakpoints: $global-prototype-breakpoints; -$prototype-text-overflow: ellipsis; - -// 46. Responsive Embed -// -------------------- - -$responsive-embed-margin-bottom: rem-calc(16); -$responsive-embed-ratios: ( - default: 4 by 3, - widescreen: 16 by 9, -); - -// 47. Reveal -// ---------- - -$reveal-background: $white; -$reveal-width: 600px; -$reveal-max-width: $global-width; -$reveal-padding: $global-padding; -$reveal-border: 1px solid $medium-gray; -$reveal-radius: $global-radius; -$reveal-zindex: 1005; -$reveal-overlay-background: rgba($black, 0.45); - -// 48. Slider -// ---------- - -$slider-width-vertical: 0.5rem; -$slider-transition: all 0.2s ease-in-out; -$slider-height: 0.5rem; -$slider-background: $light-gray; -$slider-fill-background: $medium-gray; -$slider-handle-height: 1.4rem; -$slider-handle-width: 1.4rem; -$slider-handle-background: $primary-color; -$slider-opacity-disabled: 0.25; -$slider-radius: $global-radius; - -// 49. Switch -// ---------- - -$switch-background: $medium-gray; -$switch-background-active: $primary-color; -$switch-height: 2rem; -$switch-height-tiny: 1.5rem; -$switch-height-small: 1.75rem; -$switch-height-large: 2.5rem; -$switch-radius: $global-radius; -$switch-margin: $global-margin; -$switch-paddle-background: $white; -$switch-paddle-offset: 0.25rem; -$switch-paddle-radius: $global-radius; -$switch-paddle-transition: all 0.25s ease-out; - -// 50. Table -// --------- - -$table-background: $white; -$table-color-scale: 5%; -$table-border: 1px solid smart-scale($table-background, $table-color-scale); -$table-padding: rem-calc(8 10 10); -$table-hover-scale: 2%; -$table-row-hover: darken($table-background, $table-hover-scale); -$table-row-stripe-hover: darken($table-background, $table-color-scale + $table-hover-scale); -$table-is-striped: true; -$table-striped-background: smart-scale($table-background, $table-color-scale); -$table-stripe: even; -$table-head-background: smart-scale($table-background, $table-color-scale / 2); -$table-head-row-hover: darken($table-head-background, $table-hover-scale); -$table-foot-background: smart-scale($table-background, $table-color-scale); -$table-foot-row-hover: darken($table-foot-background, $table-hover-scale); -$table-head-font-color: $body-font-color; -$table-foot-font-color: $body-font-color; -$show-header-for-stacked: false; -$table-stack-breakpoint: medium; - -// 51. Tabs -// -------- - -$tab-margin: 0; -$tab-background: $white; -$tab-color: $primary-color; -$tab-background-active: $light-gray; -$tab-active-color: $primary-color; -$tab-item-font-size: rem-calc(12); -$tab-item-background-hover: $white; -$tab-item-padding: 1.25rem 1.5rem; -$tab-content-background: $white; -$tab-content-border: $light-gray; -$tab-content-color: $body-font-color; -$tab-content-padding: 1rem; - -// 52. Thumbnail -// ------------- - -$thumbnail-border: 4px solid $white; -$thumbnail-margin-bottom: $global-margin; -$thumbnail-shadow: 0 0 0 1px rgba($black, 0.2); -$thumbnail-shadow-hover: 0 0 6px 1px rgba($primary-color, 0.5); -$thumbnail-transition: box-shadow 200ms ease-out; -$thumbnail-radius: $global-radius; - -// 53. Title Bar -// ------------- - -$titlebar-background: $black; -$titlebar-color: $white; -$titlebar-padding: 0.5rem; -$titlebar-text-font-weight: bold; -$titlebar-icon-color: $white; -$titlebar-icon-color-hover: $medium-gray; -$titlebar-icon-spacing: 0.25rem; - -// 54. Tooltip -// ----------- - -$has-tip-cursor: help; -$has-tip-font-weight: $global-weight-bold; -$has-tip-border-bottom: dotted 1px $dark-gray; -$tooltip-background-color: $black; -$tooltip-color: $white; -$tooltip-padding: 0.75rem; -$tooltip-max-width: 10rem; -$tooltip-font-size: $small-font-size; -$tooltip-pip-width: 0.75rem; -$tooltip-pip-height: $tooltip-pip-width * 0.866; -$tooltip-radius: $global-radius; - -// 55. Top Bar -// ----------- - -$topbar-padding: 0.5rem; -$topbar-background: $light-gray; -$topbar-submenu-background: $topbar-background; -$topbar-title-spacing: 0.5rem 1rem 0.5rem 0; -$topbar-input-width: 200px; -$topbar-unstack-breakpoint: medium; - -// 56. Xy Grid -// ----------- - -$xy-grid: true; -$grid-container: $global-width; -$grid-columns: 12; -$grid-margin-gutters: ( - small: 20px, - medium: 30px -); -$grid-padding-gutters: $grid-margin-gutters; -$grid-container-padding: $grid-padding-gutters; -$grid-container-max: $global-width; -$xy-block-grid-max: 8; - diff --git a/examples/foundation/src/assets/scss/app.scss b/examples/foundation/src/assets/scss/app.scss deleted file mode 100644 index 7b2525ed0..000000000 --- a/examples/foundation/src/assets/scss/app.scss +++ /dev/null @@ -1,64 +0,0 @@ -@charset 'utf-8'; - -@import 'settings'; -@import 'foundation'; -@import 'motion-ui'; - -// Global styles -@include foundation-global-styles; -@include foundation-forms; -@include foundation-typography; - -// Grids (choose one) -@include foundation-xy-grid-classes; -// @include foundation-grid; -// @include foundation-flex-grid; - -// Generic components -@include foundation-button; -@include foundation-button-group; -@include foundation-close-button; -@include foundation-label; -@include foundation-progress-bar; -@include foundation-slider; -@include foundation-switch; -@include foundation-table; -// Basic components -@include foundation-badge; -@include foundation-breadcrumbs; -@include foundation-callout; -@include foundation-card; -@include foundation-dropdown; -@include foundation-pagination; -@include foundation-tooltip; - -// Containers -@include foundation-accordion; -@include foundation-media-object; -@include foundation-orbit; -@include foundation-responsive-embed; -@include foundation-tabs; -@include foundation-thumbnail; -// Menu-based containers -@include foundation-menu; -@include foundation-menu-icon; -@include foundation-accordion-menu; -@include foundation-drilldown-menu; -@include foundation-dropdown-menu; - -// Layout components -@include foundation-off-canvas; -@include foundation-reveal; -@include foundation-sticky; -@include foundation-title-bar; -@include foundation-top-bar; - -// Helpers -@include foundation-float-classes; -@include foundation-flex-classes; -@include foundation-visibility-classes; -// @include foundation-prototype-classes; - -// Motion UI -@include motion-ui-transitions; -@include motion-ui-animations; diff --git a/examples/foundation/src/assets/scss/components/.gitkeep b/examples/foundation/src/assets/scss/components/.gitkeep deleted file mode 100644 index e69de29bb..000000000 diff --git a/examples/foundation/src/assets/scss/global/_typography.scss b/examples/foundation/src/assets/scss/global/_typography.scss deleted file mode 100644 index e69de29bb..000000000 diff --git a/examples/foundation/src/data/.gitkeep b/examples/foundation/src/data/.gitkeep deleted file mode 100644 index e69de29bb..000000000 diff --git a/examples/foundation/src/layouts/default.html b/examples/foundation/src/layouts/default.html deleted file mode 100644 index 01ee96d0d..000000000 --- a/examples/foundation/src/layouts/default.html +++ /dev/null @@ -1,19 +0,0 @@ -{{!-- This is the base layout for your project, and will be used on every page unless specified. --}} - - - - - - - - Foundation for Sites - - - - -{{!-- Pages you create in the src/pages/ folder are inserted here when the flattened page is created. --}} -{{> body}} - - - - diff --git a/examples/foundation/src/pages/index.html b/examples/foundation/src/pages/index.html deleted file mode 100644 index 9ac450e3a..000000000 --- a/examples/foundation/src/pages/index.html +++ /dev/null @@ -1,153 +0,0 @@ -
-
-
-

Welcome to Foundation

-
-
- -
-
-
-

We’re stoked you want to try Foundation!

-

To get going, this file (index.html) includes some basic styles you can modify, play around with, or totally destroy to get going.

-

Once you've exhausted the fun in this document, you should check out:

-
-
-

Foundation Documentation
Everything you need to know about using the framework.

-
-
-

Foundation Code Skills
These online courses offer you a chance to better understand how Foundation works and how you can master it to create awesome projects.

-
-
-

Foundation Forum
Join the Foundation community to ask a question or show off your knowlege.

-
-
-
-
-

Foundation on Github
Latest code, issue reports, feature requests and more.

-
-
-

@zurbfoundation
Ping us on Twitter if you have questions. When you build something with this we'd love to see it (and send you a totally boss sticker).

-
-
-
-
-
- -
-
-
Here’s your basic grid:
- - -
-
-
-

This is a twelve cell section in a grid-x. Each of these includes a div.callout element so you can see where the cell are - it's not required at all for the grid.

-
-
-
-
-
-
-

Six cell

-
-
-
-
-

Six cell

-
-
-
-
-
-
-

Four cell

-
-
-
-
-

Four cell

-
-
-
-
-

Four cell

-
-
-
- -
- -
We bet you’ll need a form somewhere:
-
-
-
- - -
-
-
-
- - -
-
- - -
-
-
- -
- - .com -
-
-
-
-
-
- - -
-
-
-
- - - -
-
- - - -
-
-
-
- - -
-
-
-
- -
-
Try one of these buttons:
-

Simple Button
- Success Btn
- Alert Btn
- Secondary Btn

-
-
So many components, girl!
-

A whole kitchen sink of goodies comes with Foundation. Check out the docs to see them all, along with details on making them your own.

- Go to Foundation Docs -
-
-
-
diff --git a/examples/foundation/src/partials/.gitkeep b/examples/foundation/src/partials/.gitkeep deleted file mode 100644 index e69de29bb..000000000 diff --git a/examples/foundation/src/styleguide/index.md b/examples/foundation/src/styleguide/index.md deleted file mode 100644 index daf010e0c..000000000 --- a/examples/foundation/src/styleguide/index.md +++ /dev/null @@ -1,347 +0,0 @@ -# The Grid - -

Problem: You've got tons of content, each needing different sized cells, and don't know how to quick and easily get it all done. Solution: The awesome XY grid!

- ---- - -## Overview - -The grid is built around two key elements: grid-x and cells. grid-container create a max-width and contain the grid, and cells create the final structure. Everything on your page that you don't give a specific structural style to should be within a grid-x or cell. - ---- - -## Nesting - -In the Grid you can nest cells down as far as you'd like. Just embed grid-x inside cells and go from there. Each embedded grid-x can contain up to 12 cells. - ---- - -## How to Use - -Using this framework is easy. Here's how your code will look when you use a series of `
` tags to create cells. - -```html -
-
...
-
...
-
-``` - -
-
4
-
4
-
4
-
-
-
3
-
6
-
3
-
-
-
2
-
8
-
2
-
-
-
3
-
9
-
-
-
4
-
8
-
-
-
5
-
7
-
-
-
6
-
6
-
- ---- - -## Nesting grid-x - -In the Grid you can nest cells down as far as you'd like. Just embed grid-x inside cells and go from there. Each embedded grid-x can contain up to 12 cells. - -```html -
-
- 8 -
-
- 8 Nested -
-
8 Nested Again
-
4
-
-
-
4
-
-
-
4
-
-``` - -
-
8 -
-
8 Nested -
-
8 Nested Again
-
4
-
-
-
4
-
-
-
4
-
- ---- - -## Small Grid - -As you've probably noticed in the examples above, you have access to a small, medium, and large grid. If you know that your grid structure will be the same for small devices as it will be on large devices, just use the small grid. You can override your small grid classes by adding medium or large grid classes. - -```html -
-
2
-
10, last
-
-
-
3
-
9, last
-
-``` - -
-
2
-
10, last
-
-
-
3
-
9, last
-
- -# Colors - -

Below you can find the different values we created that support the primary color variable you can change at any time in \_settings.scss

- ---- - -
-
-
- - #2199e8 -
-
-
-
- - #3adb76 -
-
-
-
- - #ffae00 -
-
-
-
- - #ec5840 -
-
-
-
- - #0a0a0a -
-
-
- -# Typography - -

This design uses Helvetica Neue for headings and paragraph text.

- ---- - -## Headings - -Headings are used to denote different sections of content, usually consisting of related paragraphs and other HTML elements. They range from h1 to h6 and should be styled in a clear hierarchy (i.e., largest to smallest) - ---- - -## Paragraphs - -Paragraphs are groups of sentences, each with a lead (first sentence) and transition (last sentence). They are block level elements, meaning they stack vertically when repeated. Use them as such. - ---- - -

Heading Level 1

- -Lorem ipsum dolor sit amet, consectetur adipisicing elit. Hic quibusdam ratione sunt dolorum, qui illo maxime doloremque accusantium cum libero eum, a optio odio placeat debitis ullam aut non distinctio. - -

Heading Level 2

- -Lorem ipsum dolor sit amet, consectetur adipisicing elit. Hic quibusdam ratione sunt dolorum, qui illo maxime doloremque accusantium cum libero eum, a optio odio placeat debitis ullam aut non distinctio. - -

Heading Level 3

- -Lorem ipsum dolor sit amet, consectetur adipisicing elit. Hic quibusdam ratione sunt dolorum, qui illo maxime doloremque accusantium cum libero eum, a optio odio placeat debitis ullam aut non distinctio. - -

Heading Level 4

- -Lorem ipsum dolor sit amet, consectetur adipisicing elit. Hic quibusdam ratione sunt dolorum, qui illo maxime doloremque accusantium cum libero eum, a optio odio placeat debitis ullam aut non distinctio. - -
Heading Level 5
- -Lorem ipsum dolor sit amet, consectetur adipisicing elit. Hic quibusdam ratione sunt dolorum, qui illo maxime doloremque accusantium cum libero eum, a optio odio placeat debitis ullam aut non distinctio. - -
Heading Level 6
- -Lorem ipsum dolor sit amet, consectetur adipisicing elit. Hic quibusdam ratione sunt dolorum, qui illo maxime doloremque accusantium cum libero eum, a optio odio placeat debitis ullam aut non distinctio. - -# Buttons - -

Buttons are tied to an action of some kind, whether that button is on a cheese dispenser or launches the rocket that you're strapped to. On the web, we follow similar conventions.

- ---- - -## Primary Buttons - -These buttons are primary calls to action and should be used sparingly. Their size can be adjusted with the `.tiny`, `.small`, and `.large` classes. - -```html_example -Large button -Regular button -Small button -Tiny button -``` - ---- - -## Secondary Buttons - -These buttons are used for less important, secondary actions on a page. - -```html_example -Large button -Regular button -Small button -Tiny button -``` - -# Forms - -

Use forms to allow users to interact with the site and provide information to the company.

- ---- - -## Elements of a Form - -A form should be marked up using its default HTML properties. The ones we make use of include (in hierarchical order): - -- Form -- Label -- Input -- Select -- Text area -- Button - ---- - -## How to Use - -Make forms great and easy to use with the following rules: - -- Wrap checkboxes and radio buttons within labels for larger hit areas, and be sure to set the for, name, and id attributes for all applicable elements. -- Series of checkboxes and radio buttons below within a `
    `. -- Before selecting any set of fields to use for a required input, explore other options (e.g., radio buttons over select lists). - ---- - -## Learn All About Forms - -Check out the [Foundation Docs](http://foundation.zurb.com/sites/docs) to learn about how flexible our forms are for creating different layouts. It works perfectly with the grid to meet all your form needs. - ---- - -## Form Layouts - -Form elements in Foundation are styled based on their type attribute rather than a class. Inputs in Foundation have another major advantage โ€” they are full width by default. That means that inputs will run as wide as the column that contains them. However, you have two options which make these forms extremely versatile: - -- You can size inputs using column sizes, like `.medium-6`, `.small-6`. -- You can create row elements inside your form and use columns for the form, including inputs, labels and more. Rows inside a form inherit some special padding to even up input spacing. - ---- - -## Form Example - -```html_example -
    -
    -
    - - -
    -
    -
    -
    - - -
    -
    -
    - -
    - - .com -
    -
    -
    -
    -
    -
    - - -
    -
    -
    -
    - - - -
    -
    - - - -
    -
    -
    -
    - - -
    -
    -
    -``` - -# New Section - -Lorem ipsum dolor sit amet, consectetur adipisicing elit. Tempora omnis suscipit id ut laborum recusandae molestias hic aliquid **expedita!** [Non dicta](zurb.com), autem obcaecati error, id ab voluptate unde culpa nulla. - -```html_example -Button -Button -Button -``` diff --git a/examples/foundation/src/styleguide/template.html b/examples/foundation/src/styleguide/template.html deleted file mode 100644 index 4ad210ea4..000000000 --- a/examples/foundation/src/styleguide/template.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - Style Guide - - - - - - - - -
    -
    -

    Style Guide

    -

    This style guide was built with Foundation for Sites. For more information on how to use this responsive front-end framework, check out the documentation, get help from the Foundation community, or request immediate technical support.

    - Visit the Docs - Foundation Forum - Technical Support -
    -
    - -
    -
    - -
    -
    - -
    -
    - -
    - {{#each pages}} -
    - {{ body }} -
    - {{/each}} -
    - -
    -
    - - - - diff --git a/examples/hyperapp/.editorconfig b/examples/hyperapp/.editorconfig deleted file mode 100644 index 904703930..000000000 --- a/examples/hyperapp/.editorconfig +++ /dev/null @@ -1,15 +0,0 @@ -root = true - -[*] -end_of_line = lf -charset = utf-8 -trim_trailing_whitespace = true -insert_final_newline = true -indent_style = space -indent_size = 4 - -[*.json] -indent_size = 2 - -[*.{diff,md}] -trim_trailing_whitespace = false diff --git a/examples/hyperapp/.gitignore b/examples/hyperapp/.gitignore deleted file mode 100644 index b72eef778..000000000 --- a/examples/hyperapp/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -node_modules -dist -release -.env -.env.build \ No newline at end of file diff --git a/examples/hyperapp/README.md b/examples/hyperapp/README.md deleted file mode 100644 index 14d96b424..000000000 --- a/examples/hyperapp/README.md +++ /dev/null @@ -1,29 +0,0 @@ -# HyperApp Example - -This directory is a brief example of a [HyperApp](https://github.com/jorgebucaran/hyperapp) app that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own HyperApp project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/hyperapp) - -_Live Example: https://hyperapp.now-examples.now.sh_ - -### How We Created This Example - -To get started with HyperApp on Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project: - -```shell -$ now init hyperapp -``` - -> The only change made is to amend the `releaseTarget` to `"public"` in the `taskfile.js` file. - -### Deploying From Your Terminal - -You can deploy your new HyperApp project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/hyperapp/package.json b/examples/hyperapp/package.json deleted file mode 100644 index 8a8168027..000000000 --- a/examples/hyperapp/package.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "name": "hyperapp-boilerplate", - "version": "0.0.4", - "description": "This is a sample/boilerplate project that shows how to create a production-ready hyperapp application.", - "scripts": { - "build": "taskr build release", - "start": "taskr watch", - "preserve": "npm run build", - "serve": "serve release -s -p 4000" - }, - "main": "src/app.js", - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/tzellman/hyperapp-boilerplate.git" - }, - "author": "Tom Zellman (@tzellman)", - "license": "MIT", - "bugs": { - "url": "https://github.com/tzellman/hyperapp-boilerplate/issues" - }, - "homepage": "https://github.com/tzellman/hyperapp-boilerplate#readme", - "devDependencies": { - "@taskr/clear": "^1.1.0", - "@taskr/concat": "^1.1.0", - "@taskr/esnext": "^1.1.0", - "@taskr/htmlmin": "^1.1.0", - "@taskr/postcss": "^1.1.2", - "@taskr/rev": "^1.1.0", - "@taskr/sass": "^1.1.0", - "@taskr/uglify": "^1.1.0", - "@taskr/watch": "^1.1.0", - "autoprefixer": "9.6.1", - "browser-sync": "2.26.7", - "fly-precache": "^2.1.0", - "fly-rollup": "^2.1.0", - "rollup": "^0.50.0", - "rollup-plugin-buble": "^0.16.0", - "rollup-plugin-commonjs": "^8.0.2", - "rollup-plugin-node-resolve": "^3.0.0", - "rollup-plugin-replace": "2.2.0", - "serve": "11.0.2", - "taskr": "^1.1.0" - }, - "dependencies": { - "hyperapp": "1.2.10" - } -} diff --git a/examples/hyperapp/src/actions/counter.js b/examples/hyperapp/src/actions/counter.js deleted file mode 100644 index fcc807032..000000000 --- a/examples/hyperapp/src/actions/counter.js +++ /dev/null @@ -1,6 +0,0 @@ -const actions = { - add: () => state => ({ num: state.num + 1, clicks: state.clicks + 1 }), - sub: () => state => ({ num: state.num - 1, clicks: state.clicks + 1 }), -}; - -export default actions; diff --git a/examples/hyperapp/src/app.js b/examples/hyperapp/src/app.js deleted file mode 100644 index dd76996d6..000000000 --- a/examples/hyperapp/src/app.js +++ /dev/null @@ -1,7 +0,0 @@ -import './service-worker-registration'; -import { app } from 'hyperapp'; -import actions from './actions/counter'; -import state from './states/counter'; -import view from './views/counter'; - -app(state, actions, view, document.body); diff --git a/examples/hyperapp/src/index.html b/examples/hyperapp/src/index.html deleted file mode 100644 index a9d13ceca..000000000 --- a/examples/hyperapp/src/index.html +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - Hyperapp Boilerplate - - - - - - - diff --git a/examples/hyperapp/src/service-worker-registration.js b/examples/hyperapp/src/service-worker-registration.js deleted file mode 100644 index ac2721e66..000000000 --- a/examples/hyperapp/src/service-worker-registration.js +++ /dev/null @@ -1,71 +0,0 @@ -/** - * Copyright 2015 Google Inc. All rights reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/* eslint-env browser */ -'use strict'; - -if ('serviceWorker' in navigator) { - // Delay registration until after the page has loaded, to ensure that our - // precaching requests don't degrade the first visit experience. - // See https://developers.google.com/web/fundamentals/instant-and-offline/service-worker/registration - window.addEventListener('load', function() { - // Your service-worker.js *must* be located at the top-level directory relative to your site. - // It won't be able to control pages unless it's located at the same level or higher than them. - // *Don't* register service worker file in, e.g., a scripts/ sub-directory! - // See https://github.com/slightlyoff/ServiceWorker/issues/468 - navigator.serviceWorker - .register('service-worker.js') - .then(function(reg) { - // updatefound is fired if service-worker.js changes. - reg.onupdatefound = function() { - // The updatefound event implies that reg.installing is set; see - // https://w3c.github.io/ServiceWorker/#service-worker-registration-updatefound-event - var installingWorker = reg.installing; - - installingWorker.onstatechange = function() { - switch (installingWorker.state) { - case 'installed': - if (navigator.serviceWorker.controller) { - // At this point, the old content will have been purged and the fresh content will - // have been added to the cache. - // It's the perfect time to display a "New content is available; please refresh." - // message in the page's interface. - console.log( - 'New or updated content is available.' - ); - } else { - // At this point, everything has been precached. - // It's the perfect time to display a "Content is cached for offline use." message. - console.log( - 'Content is now available offline!' - ); - } - break; - - case 'redundant': - console.error( - 'The installing service worker became redundant.' - ); - break; - } - }; - }; - }) - .catch(function(e) { - console.error('Error during service worker registration:', e); - }); - }); -} diff --git a/examples/hyperapp/src/states/counter.js b/examples/hyperapp/src/states/counter.js deleted file mode 100644 index db61d59ef..000000000 --- a/examples/hyperapp/src/states/counter.js +++ /dev/null @@ -1,6 +0,0 @@ -const state = { - num: 0, - clicks: 0, -}; - -export default state; diff --git a/examples/hyperapp/src/styles/_variables.scss b/examples/hyperapp/src/styles/_variables.scss deleted file mode 100644 index bad803c93..000000000 --- a/examples/hyperapp/src/styles/_variables.scss +++ /dev/null @@ -1,8 +0,0 @@ -/* Variables */ -$color-heading: #111; -$color-text: #444; -$font-family: sans-serif; - -$color-add: mediumseagreen; -$color-sub: mediumvioletred; -$color-outline: darkturquoise; diff --git a/examples/hyperapp/src/styles/app.scss b/examples/hyperapp/src/styles/app.scss deleted file mode 100644 index 3bb7905d4..000000000 --- a/examples/hyperapp/src/styles/app.scss +++ /dev/null @@ -1,60 +0,0 @@ -@import "variables"; - -/* Simple reset. */ -body, -* { - box-sizing: border-box; - margin: 0; -} - -body { - padding: 2rem; - color: $color-text; - font-family: $font-family; - font-size: 18px; -} - -.counter { - text-align: center; - - h1 { - color: $color-heading; - } - - section > h1 { - padding: 1rem 0; - } - - button { - border-color: black; - border-radius: 3px; - border-style: solid; - border-width: 1px; - width: 30px; - height: 30px; - outline-color: $color-outline; - cursor: pointer; - - &.add { - background-color: $color-add; - font-size: 20px; - color: black; - } - - &.sub { - background-color: $color-sub; - font-size: 20px; - color: black; - - &:disabled { - background-color: lighten($color-sub, 50%); - cursor: not-allowed; - } - } - } - - .line-break { - width: 100%; - margin: 30px 0; - } -} diff --git a/examples/hyperapp/src/views/counter.js b/examples/hyperapp/src/views/counter.js deleted file mode 100644 index a39870d98..000000000 --- a/examples/hyperapp/src/views/counter.js +++ /dev/null @@ -1,41 +0,0 @@ -import { h } from 'hyperapp'; - -const clickCount = clicks => { - return clicks > 0 ? ( -
    - You clicked {clicks} time{clicks > 1 ? 's' : ''} -
    - ) : ( - '' - ); -}; - -const Button = ({ className, label, update, disabled }) => ( - -); - -const view = (state, actions) => ( -
    -

    Welcome to HyperApp!

    -
    -
    - {Button({ className: 'add', label: '+', update: actions.add })} -

    {state.num}

    - {Button({ - className: 'sub', - label: '-', - update: actions.sub, - disabled: state.num <= 0, - })} - {clickCount(state.clicks)} -
    -
    -); - -export default view; diff --git a/examples/hyperapp/taskfile.js b/examples/hyperapp/taskfile.js deleted file mode 100644 index 8fed8001f..000000000 --- a/examples/hyperapp/taskfile.js +++ /dev/null @@ -1,133 +0,0 @@ -const browserSync = require('browser-sync'); - -let isWatching = false; - -// some source/dest consts -const target = 'dist'; -const releaseTarget = 'public'; -const src = { - js: 'src/**/*.js', - scss: 'src/styles/app.scss', - staticAssets: ['src/static/**/*.*', 'src/*.html'], - vendor: [], -}; - -export async function clean(taskr) { - await taskr.clear([target, releaseTarget]); -} - -export async function copyStaticAssets(taskr, o) { - await taskr.source(o.src || src.staticAssets).target(target); -} - -export async function vendors(taskr) { - await taskr - .source(src.vendor) - .concat('vendor.js') - .target(`${target}`); -} - -export async function js(taskr) { - await taskr - .source('src/app.js') - .rollup({ - rollup: { - plugins: [ - require('rollup-plugin-buble')({ jsx: 'h' }), - require('rollup-plugin-commonjs')(), - require('rollup-plugin-replace')({ - 'process.env.NODE_ENV': JSON.stringify( - isWatching ? 'development' : 'production' - ), - }), - require('rollup-plugin-node-resolve')({ - browser: true, - main: true, - }), - ], - }, - bundle: { - format: 'iife', - sourceMap: isWatching, - moduleName: 'window', - }, - }) - .target(`${target}`); -} - -export async function styles(taskr) { - await taskr - .source(src.scss) - .sass({ - outputStyle: 'compressed', - includePaths: [], - }) - .postcss({ - plugins: [ - require('autoprefixer')({ browsers: ['last 2 versions'] }), - ], - }) - .target(`${target}`); -} - -export async function build(taskr) { - // TODO add linting - await taskr.serial([ - 'clean', - 'copyStaticAssets', - 'styles', - 'js', - 'vendors', - ]); -} - -export async function release(taskr) { - await taskr - .source(`${target}/*.js`) - .uglify({ - compress: { - conditionals: 1, - drop_console: 1, - comparisons: 1, - join_vars: 1, - booleans: 1, - loops: 1, - }, - }) - .target(target); - await taskr - .source(`${target}/**/*`) - .rev({ - ignores: ['.html', '.png', '.svg', '.ico', '.json', '.txt'], - }) - .revManifest({ dest: releaseTarget, trim: target }) - .revReplace() - .target(releaseTarget); - await taskr - .source(`${releaseTarget}/*.html`) - .htmlmin() - .target(releaseTarget); - await taskr - .source(`${releaseTarget}/**/*.{js,css,html,png,jpg,gif}`) - .precache({ stripPrefix: `${releaseTarget}/` }) - .target(releaseTarget); -} - -export async function watch(taskr) { - isWatching = true; - await taskr.start('build'); - await taskr.watch(src.js, ['js', 'reload']); - await taskr.watch(src.scss, ['styles', 'reload']); - await taskr.watch(src.staticAssets, ['copyStaticAssets', 'reload']); - // start server - browserSync({ - server: target, - logPrefix: 'hyperapp', - port: process.env.PORT || 4000, - middleware: [require('connect-history-api-fallback')()], - }); -} - -export async function reload(taskr) { - isWatching && browserSync.reload(); -} diff --git a/examples/marko/.editorconfig b/examples/marko/.editorconfig deleted file mode 100644 index f2fff9ce5..000000000 --- a/examples/marko/.editorconfig +++ /dev/null @@ -1,15 +0,0 @@ -# top-most EditorConfig file -root = true - -# Unix-style newlines with a newline ending every file -[*] -end_of_line = lf -insert_final_newline = true -indent_size = 2 - -# Matches multiple files with brace expansion notation -# Set default charset -[*.{js,json,yml}] -charset = utf-8 -indent_style = space -indent_size = 2 diff --git a/examples/marko/.eslintignore b/examples/marko/.eslintignore deleted file mode 100644 index 14fd9d5ac..000000000 --- a/examples/marko/.eslintignore +++ /dev/null @@ -1,2 +0,0 @@ -# Generated Files -*.marko.js diff --git a/examples/marko/.eslintrc.json b/examples/marko/.eslintrc.json deleted file mode 100644 index c31038d24..000000000 --- a/examples/marko/.eslintrc.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "extends": ["eslint:recommended", "prettier"], - "env": { - "browser": true, - "node": true, - "es6": true - }, - "rules": { - "no-console": "off" - } -} diff --git a/examples/marko/.gitignore b/examples/marko/.gitignore deleted file mode 100644 index 5fef12174..000000000 --- a/examples/marko/.gitignore +++ /dev/null @@ -1,24 +0,0 @@ -# OS -*.swp -.DS_Store - -# Editor Configs -.idea -.vscode -*.sublime* - -# Generated Files -dist -.cache -coverage -.nyc-output -*.marko.js -.marko-cli -.marko-devtools - -# NPM -node_modules - -# Environment Variables -.env -.env.build diff --git a/examples/marko/.nowignore b/examples/marko/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/marko/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/marko/.prettierignore b/examples/marko/.prettierignore deleted file mode 100644 index 14fd9d5ac..000000000 --- a/examples/marko/.prettierignore +++ /dev/null @@ -1,2 +0,0 @@ -# Generated Files -*.marko.js diff --git a/examples/marko/README.md b/examples/marko/README.md deleted file mode 100644 index 7ed7aae01..000000000 --- a/examples/marko/README.md +++ /dev/null @@ -1,29 +0,0 @@ -# Marko.js Example - -This directory is a brief example of a [Marko.js](https://markojs.com/) app that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own Marko.js project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/marko) - -_Live Example: https://marko.now-examples.now.sh_ - -### How We Created This Example - -To get started with Marko.js on Now, you can use the [Marko CLI](https://github.com/marko-js/cli) to initialize the project: - -```shell -$ marko create my-project -``` - -> The only change made is to add `&& mv dist public` to the build script in the `package.json` file. - -### Deploying From Your Terminal - -You can deploy your new Marko.js project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/marko/package.json b/examples/marko/package.json deleted file mode 100644 index 247f6f926..000000000 --- a/examples/marko/package.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "name": "marko", - "description": "Demo of how to build an app using marko-starter", - "version": "1.0.0", - "dependencies": { - "marko": "^4.13.10", - "marko-starter": "^2.0.4" - }, - "devDependencies": { - "eslint": "^5.9.0", - "eslint-config-prettier": "^3.3.0", - "eslint-plugin-prettier": "^3.0.0", - "marko-prettyprint": "^1.5.2", - "prettier": "^1.15.2" - }, - "license": "MIT", - "repository": { - "type": "git", - "url": "https://github.com/marko-js-samples/marko-starter-demo" - }, - "scripts": { - "build": "NODE_ENV=production marko-starter build && mv dist public", - "format": "prettier src/**/*.{js,css,less} --write && marko-prettyprint src", - "lint": "eslint src", - "serve": "NODE_ENV=production marko-starter serve-static", - "dev": "NODE_ENV=production marko-starter serve-static --port $PORT", - "start": "marko-starter server", - "test": "npm run lint" - }, - "private": true -} diff --git a/examples/marko/project.js b/examples/marko/project.js deleted file mode 100644 index ca7522c55..000000000 --- a/examples/marko/project.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = require('marko-starter').projectConfig({ - name: 'marko-starter-demo', // Optional, but added here for demo purposes -}); diff --git a/examples/marko/server.js b/examples/marko/server.js deleted file mode 100644 index 974635f7f..000000000 --- a/examples/marko/server.js +++ /dev/null @@ -1,3 +0,0 @@ -require('./project').server({ - httpPort: process.env.PORT || 8080, // Optional, but added here for demo purposes -}); diff --git a/examples/marko/src/components/click-count/index.marko b/examples/marko/src/components/click-count/index.marko deleted file mode 100644 index ef82c5251..000000000 --- a/examples/marko/src/components/click-count/index.marko +++ /dev/null @@ -1,22 +0,0 @@ -class { - onCreate() { - this.state = { count: 0 }; - } - increment() { - this.state.count++; - } -} - -style { - .count { - color: #70b; - font-size: 3em; - } - .example-button { - font-size: 1em; - padding: 0.5em; - } -} - -${state.count}
-Click me! diff --git a/examples/marko/src/components/site-layout/index.marko b/examples/marko/src/components/site-layout/index.marko deleted file mode 100644 index 7747c752a..000000000 --- a/examples/marko/src/components/site-layout/index.marko +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - <${input.title}/> - - - -
- -

- <${input.title}/> -

- - home - routes - layouts - -
- - <${input.content}/> - - - diff --git a/examples/marko/src/components/site-layout/logo.png b/examples/marko/src/components/site-layout/logo.png deleted file mode 100644 index 12ee9ec32..000000000 Binary files a/examples/marko/src/components/site-layout/logo.png and /dev/null differ diff --git a/examples/marko/src/components/site-layout/style.css b/examples/marko/src/components/site-layout/style.css deleted file mode 100644 index ade2ddce2..000000000 --- a/examples/marko/src/components/site-layout/style.css +++ /dev/null @@ -1,78 +0,0 @@ -body { - font-family: sans-serif; - background: #eee; - padding: 0; - margin: 0; - color: #333; -} - -a { - color: #26a; - text-decoration: none; - font-weight: 500; -} - -a:hover { - text-decoration: underline; -} - -header { - padding: 2em; - border-bottom: 1px solid #ccc; - background: #fff; - text-align: center; -} - -nav.menu a { - display: inline-block; - padding: 0.5em 1em; -} - -img.logo { - width: 160px; - height: 88px; - margin-bottom: 1em; -} - -h1 { - font-size: 2.5em; - font-weight: 300; - margin: 0; -} - -h2 { - font-weight: 600; - margin-top: 1.5em; - margin-bottom: 0.5em; -} - -h3 { - font-weight: 600; - margin-top: 1.5em; - margin-bottom: 0.5em; - font-size: 1em; -} - -p { - line-height: 1.6; -} - -.content { - padding: 1em 2em; - max-width: 30em; - margin: auto; -} - -code { - color: #d03; - background-color: #f9f9f9; - padding: 0.1em 0.4em; - border: 1px solid #e5e5e5; - border-radius: 0.15em; - display: inline-block; -} - -pre code { - display: block; - color: #396; -} diff --git a/examples/marko/src/index.marko b/examples/marko/src/index.marko deleted file mode 100644 index 7f5bfbedf..000000000 --- a/examples/marko/src/index.marko +++ /dev/null @@ -1,32 +0,0 @@ - - <@title>Marko Starter - <@content> -
-

Hello!

-

- We're glad you've decided to try out Marko. You're looking at the result of - ~/src/index.marko. Try editing that file and this page will reload. ⚡ -

-
-
-

Components

-

- Here's a counter component. You click, it counts! It lives in - ~/src/components/click-count/. Try making it count by 5. -

- -

Resolving Components

-

- If you look at the code for this page, you'll notice we use the - <click-count/> - component, but don't import it from anywhere. That's because when resolving custom tags, Marko - - looks up the directory tree - - for a - components/ - directory and finds the counter for us! -

-
- -
diff --git a/examples/marko/src/routes/hello/components/stop-watch/index.marko b/examples/marko/src/routes/hello/components/stop-watch/index.marko deleted file mode 100644 index 9a2d79e68..000000000 --- a/examples/marko/src/routes/hello/components/stop-watch/index.marko +++ /dev/null @@ -1,53 +0,0 @@ -class { - onCreate() { - this.state = { - running: false, - elapsedTime: 0 - }; - - this.intervalId = null; - } - - onDestroy() { - if (this.state.running) { - clearInterval(this.intervalId); - } - } - - handleStartClick() { - this.state.running = true; - - this.intervalId = setInterval(() => { - this.state.elapsedTime += 0.1; - }, 100); - } - - handlePauseClick() { - clearInterval(this.intervalId); - - this.state.running = false; - } - - handleStopClick() { - clearInterval(this.intervalId); - - this.state.running = false; - this.state.elapsedTime = 0; - } -} - -
-

Elapsed time: ${state.elapsedTime.toFixed(1)}s

- - - -
diff --git a/examples/marko/src/routes/hello/index.marko b/examples/marko/src/routes/hello/index.marko deleted file mode 100644 index bcdd40f75..000000000 --- a/examples/marko/src/routes/hello/index.marko +++ /dev/null @@ -1,79 +0,0 @@ - - <@title> - Hello ${input.params.name}! - - <@content> -
-

Routes

-

- The code for this page is at - ~/src/routes/hello/index.marko. To create a new route, you create a directory under - routes/ - and put an - index.marko - in it. -

-

- Try creating a template at - ~/src/routes/new/index.marko - with the following content: -

-
<site-layout>
-    <@title>A New Page!</@title>
-</site-layout>
-

- Then come back and click - this link. 🎉 -

-
-
-

Parameters

-

- You might have noticed that even though - hello/index.marko - renders this page, the url is - /hello/routing. So what's going on? Parameters! -

-

- Take a look at - hello/route.js - and you'll see it contains - exports.path = '/hello/:name'. -

-

- Here, - :name - is an - - express-style parameter - - and becomes available as - input.params.name - within the template! We use this - name - in the title of the page. Try following one of these links or change the url directly and watch how the title changes: -

- -
-
-

Scoped Components

-

- Here's another component, but this one is - scoped - to this page. You see, it lives in - ~/src/routes/hello/components/ - and therefore is only available to the - hello - page! 🕶 -

- -
- -
diff --git a/examples/marko/src/routes/hello/route.js b/examples/marko/src/routes/hello/route.js deleted file mode 100644 index ba6af6701..000000000 --- a/examples/marko/src/routes/hello/route.js +++ /dev/null @@ -1,20 +0,0 @@ -exports.path = '/hello/:name'; - -// The following is used when doing static builds -// to generate all pages for all enumerated params -exports.params = [{ name: 'marko' }, { name: 'world' }, { name: 'routing' }]; - -// You can also export a custom handler -// that can do stuff before rendering the template -/* -const template = require('./index.marko'); -exports.handler = (input, out) => { - let name = input.params.name; - - // delegate rendering to the template - template.render(input, out); - - // Or don't render the template and send other content: - // out.end('...') -}; -*/ diff --git a/examples/marko/src/routes/layouts/index.marko b/examples/marko/src/routes/layouts/index.marko deleted file mode 100644 index 9c7de5073..000000000 --- a/examples/marko/src/routes/layouts/index.marko +++ /dev/null @@ -1,42 +0,0 @@ - - <@title>Layouts - <@content> -
-

Layouts

-

- If you hadn't noticed, this site has the same header on every page. This is provided by the - <site-layout> - component which lives in - ~/src/components/site-layout. This component makes use of Marko's ability to - - pass content using nested attributes - . -

-

-

-
-

Styles

-

- As you can see, this site looks quite nice. That's because Marko - - pulls in stylesheets - - next to a Marko template. Try editing the contents of - ~/src/components/site-layout/style.css. 💄 -

-
-
-

Images

-

- We also have the Marko logo in the header. The image file lives at - site-layout/logo.png, right next to - site-layout/index.marko - which references it using a relative path: - <img src="./logo.png"/>. -

-

- And this works for all resources, not just images, which allows you to keep your resources next to the templates which use them. 👍 -

-
- -
diff --git a/examples/mdx-deck/.gitignore b/examples/mdx-deck/.gitignore deleted file mode 100644 index 9ad707532..000000000 --- a/examples/mdx-deck/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -dist -node_modules -.env -.env.build \ No newline at end of file diff --git a/examples/mdx-deck/.nowignore b/examples/mdx-deck/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/mdx-deck/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/mdx-deck/README.md b/examples/mdx-deck/README.md deleted file mode 100644 index afca5622c..000000000 --- a/examples/mdx-deck/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# mdx-deck Example - -This directory is a brief example of a [mdx-deck](https://github.com/jxnblk/mdx-deck) presentation that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own mdx-deck project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/mdx-deck) - -_Live Example: https://mdx-deck.now-examples.now.sh_ - -### How We Created This Example - -To get started with mdx-deck for deployment with ZEIT Now, you can use the [npm init](https://docs.npmjs.com/cli/init) command to initialize the project: - -```shell -$ npm init deck my-presentation -``` - -### Deploying From Your Terminal - -You can deploy your new mdx-deck project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/mdx-deck/deck.mdx b/examples/mdx-deck/deck.mdx deleted file mode 100644 index 32f1c4414..000000000 --- a/examples/mdx-deck/deck.mdx +++ /dev/null @@ -1,24 +0,0 @@ -import { Head, Notes } from 'mdx-deck' -import { theme } from './theme' - -export const themes = [ theme ] - - - Presentation Title - - -# Hello - ---- - -## Edit this file - -To create your presentation - - -Create speaker notes with the Notes component - - ---- - - diff --git a/examples/mdx-deck/package.json b/examples/mdx-deck/package.json deleted file mode 100644 index 7510ceae2..000000000 --- a/examples/mdx-deck/package.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "private": true, - "name": "foo", - "version": "1.0.0", - "scripts": { - "start": "mdx-deck deck.mdx", - "dev": "mdx-deck deck.mdx --port $PORT", - "build": "mdx-deck build deck.mdx", - "help": "mdx-deck" - }, - "devDependencies": { - "mdx-deck": "^3.0.8" - } -} diff --git a/examples/mdx-deck/theme.js b/examples/mdx-deck/theme.js deleted file mode 100644 index 22b6d544b..000000000 --- a/examples/mdx-deck/theme.js +++ /dev/null @@ -1,7 +0,0 @@ -export const theme = { - // Customize your presentation theme here. - // - // Read the docs for more info: - // https://github.com/jxnblk/mdx-deck/blob/master/docs/theming.md - // https://github.com/jxnblk/mdx-deck/blob/master/docs/themes.md -}; diff --git a/examples/metalsmith/.gitignore b/examples/metalsmith/.gitignore deleted file mode 100644 index c44e47f8b..000000000 --- a/examples/metalsmith/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -node_modules -.env -.env.build \ No newline at end of file diff --git a/examples/metalsmith/.nowignore b/examples/metalsmith/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/metalsmith/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/metalsmith/Makefile b/examples/metalsmith/Makefile deleted file mode 100644 index 8d0255238..000000000 --- a/examples/metalsmith/Makefile +++ /dev/null @@ -1,8 +0,0 @@ - -build: node_modules - node index.js - -node_modules: package.json - npm install - -.PHONY: build diff --git a/examples/metalsmith/README.md b/examples/metalsmith/README.md deleted file mode 100644 index 6768c10c8..000000000 --- a/examples/metalsmith/README.md +++ /dev/null @@ -1,29 +0,0 @@ -# Metalsmith Example - -This directory is a brief example of a [Metalsmith](https://metalsmith.io/) app that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own Metalsmith project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/metalsmith) - -_Live Example: https://metalsmith.now-examples.now.sh_ - -### How We Created This Example - -To get started with Metalsmith for deployment with ZEIT Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project: - -```shell -$ now init metalsmith -``` - -> The only changes made were to add a build script in `package.json` and change the `destination` in `index.js` to be `"public"`. - -### Deploying From Your Terminal - -You can deploy your new Metalsmith project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/metalsmith/index.js b/examples/metalsmith/index.js deleted file mode 100644 index 946177039..000000000 --- a/examples/metalsmith/index.js +++ /dev/null @@ -1,27 +0,0 @@ -var Metalsmith = require('metalsmith'); -var markdown = require('metalsmith-markdown'); -var layouts = require('metalsmith-layouts'); -var permalinks = require('metalsmith-permalinks'); - -Metalsmith(__dirname) - .metadata({ - title: 'My Static Site & Blog', - description: "It's about saying ยปHelloยซ to the World.", - generator: 'Metalsmith', - url: 'http://www.metalsmith.io/', - }) - .source('./src') - .destination('./public') - .clean(false) - .use(markdown()) - .use(permalinks()) - .use( - layouts({ - engine: 'handlebars', - }) - ) - .build(function(err, files) { - if (err) { - throw err; - } - }); diff --git a/examples/metalsmith/layouts/layout.html b/examples/metalsmith/layouts/layout.html deleted file mode 100644 index 96ff05093..000000000 --- a/examples/metalsmith/layouts/layout.html +++ /dev/null @@ -1,24 +0,0 @@ - - - - - {{ title }} - - - -
-

- Home -

-
-

{{ title }}

-

{{ description }}

- - {{{ contents }}} - -
-

Generated with {{ generator }} — {{ url }}

-
- - - diff --git a/examples/metalsmith/layouts/post.html b/examples/metalsmith/layouts/post.html deleted file mode 100644 index c8da1f94a..000000000 --- a/examples/metalsmith/layouts/post.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - - {{ title }} - - - -
-

- Home -

- -
-

{{ title }}

- - {{{ contents }}} - -
-

Generated with {{ generator }} — {{ url }}

-
- - diff --git a/examples/metalsmith/package.json b/examples/metalsmith/package.json deleted file mode 100644 index a999a261d..000000000 --- a/examples/metalsmith/package.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "name": "static-site-example", - "private": true, - "dependencies": { - "handlebars": "^4.0.5", - "metalsmith": "^2.1.0", - "metalsmith-layouts": "^1.4.1", - "metalsmith-markdown": "^0.2.1", - "metalsmith-permalinks": "^0.5.0" - }, - "scripts": { - "build": "make build" - } -} diff --git a/examples/metalsmith/src/index.md b/examples/metalsmith/src/index.md deleted file mode 100644 index 6e576b018..000000000 --- a/examples/metalsmith/src/index.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -layout: layout.html ---- - -

Read what I have to say

- -First post - -Second post - -Third post - -Fourth post diff --git a/examples/metalsmith/src/posts/first-post.md b/examples/metalsmith/src/posts/first-post.md deleted file mode 100644 index 62ad941a2..000000000 --- a/examples/metalsmith/src/posts/first-post.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -title: My First Post -date: 2012-08-20 -layout: post.html ---- - -An interesting post about how it's going to be different this time around. I'm going to write a lot more nowadays and use this blog to improve my writing. diff --git a/examples/metalsmith/src/posts/fourth-post.md b/examples/metalsmith/src/posts/fourth-post.md deleted file mode 100644 index 4dbbd9878..000000000 --- a/examples/metalsmith/src/posts/fourth-post.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -title: My Fourth Post -date: 2012-12-07 -layout: post.html ---- - -A really short, rushed-feeling string of words. diff --git a/examples/metalsmith/src/posts/second-post.md b/examples/metalsmith/src/posts/second-post.md deleted file mode 100644 index 97742d5a2..000000000 --- a/examples/metalsmith/src/posts/second-post.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -title: My Second Post -date: 2012-08-23 -layout: post.html ---- - -A super-interesting piece of prose I have already written weeks ago. diff --git a/examples/metalsmith/src/posts/third-post.md b/examples/metalsmith/src/posts/third-post.md deleted file mode 100644 index f36e1ce54..000000000 --- a/examples/metalsmith/src/posts/third-post.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -title: My Third Post -date: 2012-09-28 -layout: post.html ---- - -A slightly late, less interesting piece of prose. diff --git a/examples/mithril/.gitignore b/examples/mithril/.gitignore deleted file mode 100644 index c44e47f8b..000000000 --- a/examples/mithril/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -node_modules -.env -.env.build \ No newline at end of file diff --git a/examples/mithril/.nowignore b/examples/mithril/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/mithril/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/mithril/README.md b/examples/mithril/README.md deleted file mode 100644 index 8c4b0cbac..000000000 --- a/examples/mithril/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# Mithril Example - -This directory is a brief example of a [Mithril](https://mithril.js.org/) app that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own Mithril project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/mithril) - -_Live Example: https://mithril.now-examples.now.sh_ - -### How We Created This Example - -To get started with Mithril for deployment on ZEIT Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project: - -```shell -$ now init mithril -``` - -### Deploying From Your Terminal - -You can deploy your new Mithril project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/mithril/package.json b/examples/mithril/package.json deleted file mode 100644 index bbf749e03..000000000 --- a/examples/mithril/package.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "mithril", - "version": "1.0.0", - "main": "index.js", - "license": "MIT", - "dependencies": { - "mithril": "^1.1.6" - }, - "devDependencies": { - "webpack": "^4.36.1", - "webpack-cli": "^3.3.6" - }, - "scripts": { - "start": "webpack src/index.js --output public/app.js -d --watch", - "build": "webpack src/index.js --output public/app.js -p" - } -} diff --git a/examples/mithril/src/index.js b/examples/mithril/src/index.js deleted file mode 100644 index 32c3c089b..000000000 --- a/examples/mithril/src/index.js +++ /dev/null @@ -1,37 +0,0 @@ -var m = require('mithril'); -var root = document.body; -var count = 0; - -var Hello = { - view: function() { - return m('main', [ - m('h1', { class: 'title' }, 'MithrilJS Counter'), - m( - 'button', - { - onclick: function() { - count++; - } - }, - count + ' Clicks' - ) - ]); - } -}; - -var Splash = { - view: function() { - return m( - 'a', - { - href: '#!/hello' - }, - 'Enter!' - ); - } -}; - -m.route(root, '/splash', { - '/splash': Splash, - '/hello': Hello -}); diff --git a/examples/mkdocs/.gitignore b/examples/mkdocs/.gitignore deleted file mode 100644 index 72b1dae7c..000000000 --- a/examples/mkdocs/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -.DS_Store -node_modules -.env -.env.build -public \ No newline at end of file diff --git a/examples/mkdocs/.nowignore b/examples/mkdocs/.nowignore deleted file mode 100644 index 154b26264..000000000 --- a/examples/mkdocs/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -public \ No newline at end of file diff --git a/examples/mkdocs/README.md b/examples/mkdocs/README.md deleted file mode 100644 index 52c221f3d..000000000 --- a/examples/mkdocs/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# MkDocs Example - -This directory is a brief example of a [MkDocs](https://www.mkdocs.org/) site that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own MkDocs project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/mkdocs) - -_Live Example: https://mkdocs.now-examples.now.sh_ - -### How We Created This Example - -To get started with MkDocs for deployment with ZEIT Now, you can use the [MkDocs CLI](https://www.mkdocs.org/#installation) to initialize the project: - -```shell -$ mkdocs init project-name -``` - -### Deploying From Your Terminal - -You can deploy your new MkDocs project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/mkdocs/docs/index.md b/examples/mkdocs/docs/index.md deleted file mode 100644 index a6bb2e8a0..000000000 --- a/examples/mkdocs/docs/index.md +++ /dev/null @@ -1,17 +0,0 @@ -# Welcome to MkDocs - -For full documentation visit [mkdocs.org](https://mkdocs.org). - -## Commands - -- `mkdocs new [dir-name]` - Create a new project. -- `mkdocs serve` - Start the live-reloading docs server. -- `mkdocs build` - Build the documentation site. -- `mkdocs help` - Print this help message. - -## Project layout - - mkdocs.yml # The configuration file. - docs/ - index.md # The documentation homepage. - ... # Other markdown pages, images and other files. diff --git a/examples/mkdocs/mkdocs.yml b/examples/mkdocs/mkdocs.yml deleted file mode 100644 index c97182f51..000000000 --- a/examples/mkdocs/mkdocs.yml +++ /dev/null @@ -1 +0,0 @@ -site_name: My Docs diff --git a/examples/mkdocs/package.json b/examples/mkdocs/package.json deleted file mode 100644 index e199fdb93..000000000 --- a/examples/mkdocs/package.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "mkdocs", - "version": "1.0.0", - "private": true, - "description": "An MkDocs project, ready for deployment with ZEIT Now.", - "main": "index.js", - "directories": { - "doc": "docs" - }, - "scripts": { - "dev": "mkdocs serve -a localhost:$PORT", - "build": "mkdocs build -d public" - }, - "keywords": [], - "author": "", - "license": "ISC" -} diff --git a/examples/mkdocs/requirements.txt b/examples/mkdocs/requirements.txt deleted file mode 100644 index d8fc696e6..000000000 --- a/examples/mkdocs/requirements.txt +++ /dev/null @@ -1 +0,0 @@ -mkdocs ~= 1.0.4 \ No newline at end of file diff --git a/examples/pelican/.gitignore b/examples/pelican/.gitignore deleted file mode 100644 index 4b37b5d06..000000000 --- a/examples/pelican/.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -.DS_Store -node_modules -.env -.env.build -public -output \ No newline at end of file diff --git a/examples/pelican/.nowignore b/examples/pelican/.nowignore deleted file mode 100644 index fff1fbc1b..000000000 --- a/examples/pelican/.nowignore +++ /dev/null @@ -1,3 +0,0 @@ -README.md -public -output \ No newline at end of file diff --git a/examples/pelican/Makefile b/examples/pelican/Makefile deleted file mode 100644 index 9c985406d..000000000 --- a/examples/pelican/Makefile +++ /dev/null @@ -1,75 +0,0 @@ -PY?=python3 -PELICAN?=pelican -PELICANOPTS= - -BASEDIR=$(CURDIR) -INPUTDIR=$(BASEDIR)/content -OUTPUTDIR=$(BASEDIR)/output -CONFFILE=$(BASEDIR)/pelicanconf.py -PUBLISHCONF=$(BASEDIR)/publishconf.py - - -DEBUG ?= 0 -ifeq ($(DEBUG), 1) - PELICANOPTS += -D -endif - -RELATIVE ?= 0 -ifeq ($(RELATIVE), 1) - PELICANOPTS += --relative-urls -endif - -help: - @echo 'Makefile for a pelican Web site ' - @echo ' ' - @echo 'Usage: ' - @echo ' make html (re)generate the web site ' - @echo ' make clean remove the generated files ' - @echo ' make regenerate regenerate files upon modification ' - @echo ' make publish generate using production settings ' - @echo ' make serve [PORT=8000] serve site at http://localhost:8000' - @echo ' make serve-global [SERVER=0.0.0.0] serve (as root) to $(SERVER):80 ' - @echo ' make devserver [PORT=8000] serve and regenerate together ' - @echo ' make ssh_upload upload the web site via SSH ' - @echo ' make rsync_upload upload the web site via rsync+ssh ' - @echo ' ' - @echo 'Set the DEBUG variable to 1 to enable debugging, e.g. make DEBUG=1 html ' - @echo 'Set the RELATIVE variable to 1 to enable relative urls ' - @echo ' ' - -html: - $(PELICAN) $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) - -clean: - [ ! -d $(OUTPUTDIR) ] || rm -rf $(OUTPUTDIR) - -regenerate: - $(PELICAN) -r $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) - -serve: -ifdef PORT - $(PELICAN) -l $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) -p $(PORT) -else - $(PELICAN) -l $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) -endif - -serve-global: -ifdef SERVER - $(PELICAN) -l $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) -p $(PORT) -b $(SERVER) -else - $(PELICAN) -l $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) -p $(PORT) -b 0.0.0.0 -endif - - -devserver: -ifdef PORT - $(PELICAN) -lr $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) -p $(PORT) -else - $(PELICAN) -lr $(INPUTDIR) -o $(OUTPUTDIR) -s $(CONFFILE) $(PELICANOPTS) -endif - -publish: - $(PELICAN) $(INPUTDIR) -o $(OUTPUTDIR) -s $(PUBLISHCONF) $(PELICANOPTS) - - -.PHONY: html help clean regenerate serve serve-global devserver publish \ No newline at end of file diff --git a/examples/pelican/README.md b/examples/pelican/README.md deleted file mode 100644 index 3ce320f1e..000000000 --- a/examples/pelican/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# Pelican Example - -This directory is a brief example of a [Pelican](https://docs.getpelican.com/en/stable/) site that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own Pelican project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/pelican) - -_Live Example: https://pelican.now-examples.now.sh_ - -### How We Created This Example - -To get started with Pelican for deployment with ZEIT Now, you can use the [Pelican CLI](https://docs.getpelican.com/en/stable/install.html) to initialize the project: - -```shell -$ pelican-quickstart -``` - -### Deploying From Your Terminal - -You can deploy your new Pelican project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/pelican/__pycache__/pelicanconf.cpython-37.pyc b/examples/pelican/__pycache__/pelicanconf.cpython-37.pyc deleted file mode 100644 index 2d7fc4058..000000000 Binary files a/examples/pelican/__pycache__/pelicanconf.cpython-37.pyc and /dev/null differ diff --git a/examples/pelican/package.json b/examples/pelican/package.json deleted file mode 100644 index 96dcfa23b..000000000 --- a/examples/pelican/package.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "name": "pelican", - "version": "1.0.0", - "private": true, - "description": "A Pelican project, ready for deployment with ZEIT Now.", - "main": "index.js", - "scripts": { - "build": "pelican ./ -o public -s publishconf.py" - }, - "keywords": [], - "author": "", - "license": "ISC" -} diff --git a/examples/pelican/pelicanconf.py b/examples/pelican/pelicanconf.py deleted file mode 100644 index 25bef8a61..000000000 --- a/examples/pelican/pelicanconf.py +++ /dev/null @@ -1,35 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- # -from __future__ import unicode_literals - -AUTHOR = 'ZEIT' -SITENAME = 'Pelican' -SITEURL = '' - -PATH = 'content' - -TIMEZONE = 'Europe/Paris' - -DEFAULT_LANG = 'en' - -# Feed generation is usually not desired when developing -FEED_ALL_ATOM = None -CATEGORY_FEED_ATOM = None -TRANSLATION_FEED_ATOM = None -AUTHOR_FEED_ATOM = None -AUTHOR_FEED_RSS = None - -# Blogroll -LINKS = (('Pelican', 'http://getpelican.com/'), - ('Python.org', 'http://python.org/'), - ('Jinja2', 'http://jinja.pocoo.org/'), - ('You can modify those links in your config file', '#'),) - -# Social widget -SOCIAL = (('You can add links in your config file', '#'), - ('Another social link', '#'),) - -DEFAULT_PAGINATION = False - -# Uncomment following line if you want document-relative URLs when developing -#RELATIVE_URLS = True \ No newline at end of file diff --git a/examples/pelican/publishconf.py b/examples/pelican/publishconf.py deleted file mode 100644 index 185184d4a..000000000 --- a/examples/pelican/publishconf.py +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- # -from __future__ import unicode_literals - -# This file is only used if you use `make publish` or -# explicitly specify it as your config file. - -import os -import sys -sys.path.append(os.curdir) -from pelicanconf import * - -# If your site is available via HTTPS, make sure SITEURL begins with https:// -SITEURL = '' -RELATIVE_URLS = False - -FEED_ALL_ATOM = 'feeds/all.atom.xml' -CATEGORY_FEED_ATOM = 'feeds/{slug}.atom.xml' - -DELETE_OUTPUT_DIRECTORY = True - -# Following items are often useful when publishing - -#DISQUS_SITENAME = "" -#GOOGLE_ANALYTICS = "" \ No newline at end of file diff --git a/examples/pelican/requirements.txt b/examples/pelican/requirements.txt deleted file mode 100644 index d9ac0ec1e..000000000 --- a/examples/pelican/requirements.txt +++ /dev/null @@ -1 +0,0 @@ -pelican ~= 4.1.2 \ No newline at end of file diff --git a/examples/pelican/tasks.py b/examples/pelican/tasks.py deleted file mode 100644 index 354b55431..000000000 --- a/examples/pelican/tasks.py +++ /dev/null @@ -1,109 +0,0 @@ -# -*- coding: utf-8 -*- - -import os -import shutil -import sys -import datetime - -from invoke import task -from invoke.util import cd -from pelican.server import ComplexHTTPRequestHandler, RootedHTTPServer -from pelican.settings import DEFAULT_CONFIG, get_settings_from_file - -SETTINGS_FILE_BASE = 'pelicanconf.py' -SETTINGS = {} -SETTINGS.update(DEFAULT_CONFIG) -LOCAL_SETTINGS = get_settings_from_file(SETTINGS_FILE_BASE) -SETTINGS.update(LOCAL_SETTINGS) - -CONFIG = { - 'settings_base': SETTINGS_FILE_BASE, - 'settings_publish': 'publishconf.py', - # Output path. Can be absolute or relative to tasks.py. Default: 'output' - 'deploy_path': SETTINGS['OUTPUT_PATH'], - # Port for `serve` - 'port': 8000, -} - -@task -def clean(c): - """Remove generated files""" - if os.path.isdir(CONFIG['deploy_path']): - shutil.rmtree(CONFIG['deploy_path']) - os.makedirs(CONFIG['deploy_path']) - -@task -def build(c): - """Build local version of site""" - c.run('pelican -s {settings_base}'.format(**CONFIG)) - -@task -def rebuild(c): - """`build` with the delete switch""" - c.run('pelican -d -s {settings_base}'.format(**CONFIG)) - -@task -def regenerate(c): - """Automatically regenerate site upon file modification""" - c.run('pelican -r -s {settings_base}'.format(**CONFIG)) - -@task -def serve(c): - """Serve site at http://localhost:$PORT/ (default port is 8000)""" - - class AddressReuseTCPServer(RootedHTTPServer): - allow_reuse_address = True - - server = AddressReuseTCPServer( - CONFIG['deploy_path'], - ('', CONFIG['port']), - ComplexHTTPRequestHandler) - - sys.stderr.write('Serving on port {port} ...\n'.format(**CONFIG)) - server.serve_forever() - -@task -def reserve(c): - """`build`, then `serve`""" - build(c) - serve(c) - -@task -def preview(c): - """Build production version of site""" - c.run('pelican -s {settings_publish}'.format(**CONFIG)) - -@task -def livereload(c): - """Automatically reload browser tab upon file modification.""" - from livereload import Server - build(c) - server = Server() - # Watch the base settings file - server.watch(CONFIG['settings_base'], lambda: build(c)) - # Watch content source files - content_file_extensions = ['.md', '.rst'] - for extension in content_file_extensions: - content_blob = '{0}/**/*{1}'.format(SETTINGS['PATH'], extension) - server.watch(content_blob, lambda: build(c)) - # Watch the theme's templates and static assets - theme_path = SETTINGS['THEME'] - server.watch('{}/templates/*.html'.format(theme_path), lambda: build(c)) - static_file_extensions = ['.css', '.js'] - for extension in static_file_extensions: - static_file = '{0}/static/**/*{1}'.format(theme_path, extension) - server.watch(static_file, lambda: build(c)) - # Serve output path on configured port - server.serve(port=CONFIG['port'], root=CONFIG['deploy_path']) - - -@task -def publish(c): - """Publish to production via rsync""" - c.run('pelican -s {settings_publish}'.format(**CONFIG)) - c.run( - 'rsync --delete --exclude ".DS_Store" -pthrvz -c ' - '{} {production}:{dest_path}'.format( - CONFIG['deploy_path'].rstrip('/') + '/', - **CONFIG)) - diff --git a/examples/riot/.babelrc b/examples/riot/.babelrc deleted file mode 100644 index 58a399948..000000000 --- a/examples/riot/.babelrc +++ /dev/null @@ -1,13 +0,0 @@ -{ - "presets": [ - [ - "@babel/preset-env", - { - "modules": false, - "targets": [ - "last 2 versions" - ] - } - ] - ] -} diff --git a/examples/riot/.gitignore b/examples/riot/.gitignore deleted file mode 100644 index 2fe883426..000000000 --- a/examples/riot/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -node_modules -public/bundle.js -.env -.env.build \ No newline at end of file diff --git a/examples/riot/.nowignore b/examples/riot/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/riot/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/riot/README.md b/examples/riot/README.md deleted file mode 100644 index 034103b16..000000000 --- a/examples/riot/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# Riot Example - -This directory is a brief example of a [Riot.js](https://riot.js.org/) app that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own Riot.js project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/riot) - -_Live Example: https://riot.now-examples.now.sh_ - -### How We Created This Example - -To get started with Riot.js deployed with ZEIT Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project: - -```shell -$ now init riot -``` - -### Deploying From Your Terminal - -You can deploy your new Riot.js project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/riot/package.json b/examples/riot/package.json deleted file mode 100644 index b4b20e6e6..000000000 --- a/examples/riot/package.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "name": "riot-webpack", - "version": "0.0.1", - "description": "Example of webpack and riot", - "repository": "riot/examples", - "main": "app/main.js", - "author": "Zhomart Mukhamejanov", - "license": "MIT", - "engines": { - "node": ">=4.0.0" - }, - "scripts": { - "start": "webpack-dev-server --inline --watch --hot --colors -d --port 3000", - "dev": "webpack-dev-server --inline --watch --hot --colors -d --port $PORT", - "build": "webpack -p -d --progress --colors" - }, - "keywords": [ - "riot", - "webpack" - ], - "devDependencies": { - "@babel/core": "7.4.5", - "@babel/preset-env": "7.4.5", - "babel-loader": "^8.0.6", - "riot": "^4.0.5", - "@riotjs/compiler": "^4.2.5", - "@riotjs/hot-reload": "4.0.0", - "@riotjs/webpack-loader": "^4.0.0", - "webpack": "^4.33.0", - "webpack-cli": "^3.3.2", - "webpack-dev-server": "^3.5.1" - } -} diff --git a/examples/riot/src/logs.riot b/examples/riot/src/logs.riot deleted file mode 100644 index 19157dd54..000000000 --- a/examples/riot/src/logs.riot +++ /dev/null @@ -1,13 +0,0 @@ - - -

Logs

- - - -
    -
  • { log.text }
  • -
- -
diff --git a/examples/riot/src/main.js b/examples/riot/src/main.js deleted file mode 100644 index 5bb9a4062..000000000 --- a/examples/riot/src/main.js +++ /dev/null @@ -1,7 +0,0 @@ -import '@riotjs/hot-reload'; -import { component } from 'riot'; -import Random from './random.riot'; - -component(Random)(document.getElementById('app'), { - title: 'Hi there!' -}); diff --git a/examples/riot/src/random.riot b/examples/riot/src/random.riot deleted file mode 100644 index 175ae35ee..000000000 --- a/examples/riot/src/random.riot +++ /dev/null @@ -1,40 +0,0 @@ - -

{ props.title }

- - - -

- { state.number } -

- - - - -
diff --git a/examples/riot/webpack.config.js b/examples/riot/webpack.config.js deleted file mode 100644 index b08b59865..000000000 --- a/examples/riot/webpack.config.js +++ /dev/null @@ -1,38 +0,0 @@ -const path = require('path'); -const webpack = require('webpack'); - -module.exports = { - entry: './src/main.js', - output: { - path: path.resolve(__dirname, 'public'), - publicPath: '/public/', - filename: 'bundle.js' - }, - devtool: 'inline', - module: { - rules: [ - { - test: /\.riot$/, - exclude: /node_modules/, - use: [ - { - loader: '@riotjs/webpack-loader', - options: { - hot: true - } - } - ] - }, - { - test: /\.js$/, - exclude: /node_modules/, - use: { - loader: 'babel-loader', - options: { - presets: ['@babel/preset-env'] - } - } - } - ] - } -}; diff --git a/examples/storybook/.gitignore b/examples/storybook/.gitignore deleted file mode 100644 index 694420aa3..000000000 --- a/examples/storybook/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -.DS_Store -node_modules -.env -.env.build diff --git a/examples/storybook/.nowignore b/examples/storybook/.nowignore deleted file mode 100644 index 06e345969..000000000 --- a/examples/storybook/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -yarn.lock \ No newline at end of file diff --git a/examples/storybook/.storybook/config.js b/examples/storybook/.storybook/config.js deleted file mode 100644 index 138cd99fa..000000000 --- a/examples/storybook/.storybook/config.js +++ /dev/null @@ -1,3 +0,0 @@ -import { configure } from '@storybook/react'; - -configure(require.context('../src/components', true, /\.stories\.js$/), module); diff --git a/examples/storybook/README.md b/examples/storybook/README.md deleted file mode 100644 index 81ae2b597..000000000 --- a/examples/storybook/README.md +++ /dev/null @@ -1,29 +0,0 @@ -# Storybook Example - -This directory is a brief example of a [Storybook](https://storybook.js.org/) app that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own Storybook project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/storybook) - -_Live Example: https://storybook.now-examples.now.sh_ - -### How We Created This Example - -To get started with Storybook deployed with ZEIT Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project: - -```shell -$ now init storybook -``` - -> The only change made is to amend the output directory to `"public"` in the build script. - -### Deploying From Your Terminal - -You can deploy your new Storybook project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/storybook/package.json b/examples/storybook/package.json deleted file mode 100644 index dbeacd4e9..000000000 --- a/examples/storybook/package.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "devDependencies": { - "@babel/core": "^7.6.4", - "@storybook/react": "^5.2.4", - "babel-loader": "^8.0.6" - }, - "dependencies": { - "react": "^16.10.2", - "react-dom": "^16.10.2" - }, - "scripts": { - "build": "build-storybook -c .storybook -o public", - "storybook": "start-storybook", - "dev": "start-storybook --port $PORT" - } -} diff --git a/examples/storybook/src/components/button.js b/examples/storybook/src/components/button.js deleted file mode 100644 index da8275385..000000000 --- a/examples/storybook/src/components/button.js +++ /dev/null @@ -1,3 +0,0 @@ -import { Button } from '@storybook/react/demo'; - -export default Button; diff --git a/examples/storybook/src/components/button.stories.js b/examples/storybook/src/components/button.stories.js deleted file mode 100644 index 2d52e4eda..000000000 --- a/examples/storybook/src/components/button.stories.js +++ /dev/null @@ -1,17 +0,0 @@ -import React from 'react'; -import Button from './button'; - -export default { - component: Button, - title: 'Button', -}; - -export const text = () => ; - -export const emoji = () => ( - -); diff --git a/examples/vanilla/.gitignore b/examples/vanilla/.gitignore deleted file mode 100644 index 2eea525d8..000000000 --- a/examples/vanilla/.gitignore +++ /dev/null @@ -1 +0,0 @@ -.env \ No newline at end of file diff --git a/examples/vanilla/README.md b/examples/vanilla/README.md deleted file mode 100644 index fca9c264d..000000000 --- a/examples/vanilla/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# Vanilla Example - -This directory is a brief example of a vanilla site that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own vanilla website, along with Serverless Functions, with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/vanilla) - -_Live Example: https://vanilla.now-examples.now.sh_ - -### How We Created This Example - -To get started with a vanilla website, along with [Serverless Functions](https://zeit.co/docs/v2/serverless-functions/introduction), with ZEIT Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project: - -```shell -$ now init vanilla -``` - -### Deploying From Your Terminal - -You can deploy your new vanilla website, along with [Serverless Functions](https://zeit.co/docs/v2/serverless-functions/introduction), with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/vanilla/api/date.go b/examples/vanilla/api/date.go deleted file mode 100644 index 717ed666c..000000000 --- a/examples/vanilla/api/date.go +++ /dev/null @@ -1,12 +0,0 @@ -package handler - -import ( - "fmt" - "net/http" - "time" -) - -func Handler(w http.ResponseWriter, r *http.Request) { - currentTime := time.Now().Format(time.RFC850) - fmt.Fprintf(w, currentTime) -} diff --git a/examples/vanilla/api/go.mod b/examples/vanilla/api/go.mod deleted file mode 100644 index 3403a1f96..000000000 --- a/examples/vanilla/api/go.mod +++ /dev/null @@ -1,3 +0,0 @@ -module example-date - -go 1.12 \ No newline at end of file diff --git a/examples/vanilla/index.html b/examples/vanilla/index.html deleted file mode 100644 index cee8acbbe..000000000 --- a/examples/vanilla/index.html +++ /dev/null @@ -1,46 +0,0 @@ - - - - Vanilla + Go API - - - -

Welcome to a Static Site with Data from a Go API

-

- Deployed with - ZEIT Now! -

-

- This project - includes three files. A static index.html file as the - homepage, a static style.css file for styling, and a - api/date.go serverless function that returns the date on - invocation. See - api/date.go for the Date API with Go. -

-
-

The date according to Go is:

-

Loading date...

- - - diff --git a/examples/vanilla/style.css b/examples/vanilla/style.css deleted file mode 100644 index 70ab06957..000000000 --- a/examples/vanilla/style.css +++ /dev/null @@ -1,56 +0,0 @@ -body { - font-family: 'SF Pro Text', 'SF Pro Icons', 'Helvetica Neue', 'Helvetica', - 'Arial', sans-serif; - box-sizing: border-box; - padding: 20px 20px 60px; - max-width: 680px; - display: grid; - align-content: center; - min-height: 100vh; - margin: 0 auto; - font-size: 16px; - line-height: 1.65; - word-break: break-word; - font-kerning: auto; - font-variant: normal; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; - text-rendering: optimizeLegibility; - hyphens: auto; - text-align: center; -} - -h1 { - text-align: center; - font-size: 45px; -} - -a { - cursor: pointer; - color: #0076ff; - text-decoration: none; - transition: all 0.2s ease; - border-bottom: 1px solid white; -} - -a:hover { - border-bottom: 1px solid #0076ff; -} - -code, -pre { - font-family: Menlo, Monaco, Lucida Console, Liberation Mono, DejaVu Sans Mono, - Bitstream Vera Sans Mono, Courier New, monospace, serif; - font-size: 0.92em; - color: #d400ff; -} - -code:before, -code:after { - content: '`'; -} - -p { - text-align: center; - font-size: 16px; -} diff --git a/examples/vuepress/.gitignore b/examples/vuepress/.gitignore deleted file mode 100644 index 9328e1dc4..000000000 --- a/examples/vuepress/.gitignore +++ /dev/null @@ -1,23 +0,0 @@ -.DS_Store -node_modules -/dist - -# local env files -.env.local -.env.*.local -.env -.env.build - -# Log files -npm-debug.log* -yarn-debug.log* -yarn-error.log* - -# Editor directories and files -.idea -.vscode -*.suo -*.ntvs* -*.njsproj -*.sln -*.sw? diff --git a/examples/vuepress/.nowignore b/examples/vuepress/.nowignore deleted file mode 100644 index 7255efa0b..000000000 --- a/examples/vuepress/.nowignore +++ /dev/null @@ -1 +0,0 @@ -yarn.lock \ No newline at end of file diff --git a/examples/vuepress/README.md b/examples/vuepress/README.md deleted file mode 100644 index 653d102a6..000000000 --- a/examples/vuepress/README.md +++ /dev/null @@ -1,29 +0,0 @@ -# VuePress Example - -This directory is a brief example of a [VuePress](https://vuepress.vuejs.org/) app that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own VuePress project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/vuepress) - -_Live Example: https://vuepress.now-examples.now.sh_ - -### How We Created This Example - -To get started with VuePress deployed with ZEIT Now, you can use the [Now CLI](https://zeit.co/download) to initialize the project: - -```shell -$ now init vuepress -``` - -> The only change made is to add `dest: "/public"` to the `config.js` file. - -### Deploying From Your Terminal - -You can deploy your new VuePress project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/vuepress/docs/.vuepress/config.js b/examples/vuepress/docs/.vuepress/config.js deleted file mode 100644 index 9cef3e3f9..000000000 --- a/examples/vuepress/docs/.vuepress/config.js +++ /dev/null @@ -1,12 +0,0 @@ -module.exports = { - title: 'Vuepress', - description: 'This is a Zeit Now 2.0 example', - themeConfig: { - nav: [ - { text: 'Home', link: '/' }, - { text: 'Guide', link: '/guide/' }, - { text: 'Config Page', link: '/config' }, - ], - }, - dest: 'public', -}; diff --git a/examples/vuepress/docs/README.md b/examples/vuepress/docs/README.md deleted file mode 100644 index 5cd51e096..000000000 --- a/examples/vuepress/docs/README.md +++ /dev/null @@ -1 +0,0 @@ -# Hello From Vuepress on Now 2.0! diff --git a/examples/vuepress/docs/config.md b/examples/vuepress/docs/config.md deleted file mode 100644 index 985f2e6b6..000000000 --- a/examples/vuepress/docs/config.md +++ /dev/null @@ -1 +0,0 @@ -# Example Config Route diff --git a/examples/vuepress/docs/guide/README.md b/examples/vuepress/docs/guide/README.md deleted file mode 100644 index 424935514..000000000 --- a/examples/vuepress/docs/guide/README.md +++ /dev/null @@ -1 +0,0 @@ -# Example Guide Section diff --git a/examples/vuepress/package.json b/examples/vuepress/package.json deleted file mode 100644 index 1cec679ae..000000000 --- a/examples/vuepress/package.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "name": "vuepress", - "version": "1.0.0", - "license": "MIT", - "private": true, - "scripts": { - "dev": "vuepress dev docs --port $PORT", - "build": "vuepress build docs" - }, - "devDependencies": { - "vuepress": "^0.14.4" - } -} diff --git a/examples/zola/.gitignore b/examples/zola/.gitignore deleted file mode 100644 index 72b1dae7c..000000000 --- a/examples/zola/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -.DS_Store -node_modules -.env -.env.build -public \ No newline at end of file diff --git a/examples/zola/.nowignore b/examples/zola/.nowignore deleted file mode 100644 index 154b26264..000000000 --- a/examples/zola/.nowignore +++ /dev/null @@ -1,2 +0,0 @@ -README.md -public \ No newline at end of file diff --git a/examples/zola/README.md b/examples/zola/README.md deleted file mode 100644 index 2fa49ed87..000000000 --- a/examples/zola/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# Zola Example - -This directory is a brief example of a [Zola](https://www.getzola.org/) site that can be deployed with ZEIT Now and zero configuration. - -## Deploy Your Own - -Deploy your own Zola project with ZEIT Now. - -[![Deploy with ZEIT Now](https://zeit.co/button)](https://zeit.co/import/project?template=https://github.com/zeit/now/tree/master/examples/zola) - -_Live Example: https://zola.now-examples.now.sh_ - -### How We Created This Example - -To get started with Zola for deployment with ZEIT Now, you can use the [Zola CLI](https://www.getzola.org/documentation/getting-started/cli-usage/) to initialize the project: - -```shell -$ zola init project-name -``` - -### Deploying From Your Terminal - -You can deploy your new Zola project with a single command from your terminal using [Now CLI](https://zeit.co/download): - -```shell -$ now -``` diff --git a/examples/zola/config.toml b/examples/zola/config.toml deleted file mode 100644 index 7c308f292..000000000 --- a/examples/zola/config.toml +++ /dev/null @@ -1,15 +0,0 @@ -# The URL the site will be built for -base_url = "https://zola.now-examples.now.sh" - -# Whether to automatically compile all Sass files in the sass directory -compile_sass = false - -# Whether to do syntax highlighting -# Theme can be customised by setting the `highlight_theme` variable to a theme supported by Zola -highlight_code = false - -# Whether to build a search index to be used later on by a JavaScript library -build_search_index = false - -[extra] -# Put all your custom variables here diff --git a/packages/frameworks/frameworks.json b/packages/frameworks/frameworks.json index db2762a27..4f945d0ed 100644 --- a/packages/frameworks/frameworks.json +++ b/packages/frameworks/frameworks.json @@ -668,147 +668,6 @@ } } }, - { - "name": "Vanilla", - "slug": "vanilla", - "demo": "https://vanilla.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/vanilla.svg", - "tagline": "Love the original way of making websites?", - "description": "A vanilla site and a Serverless Function API." - }, - { - "name": "Storybook", - "slug": "storybook", - "demo": "https://storybook.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/storybook.svg", - "tagline": "Storybook is an open source tool for developing UI components in isolation for React, Vue, and Angular.", - "description": "A Storybook app, using the React demo template.", - "website": "https://storybook.js.org" - }, - { - "name": "Docz", - "slug": "docz", - "demo": "https://docz.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/docz.svg", - "tagline": "Docz makes it easy to write and publish beautiful interactive documentation for your code.", - "description": "A static Docz site that can be expanded upon to create documentation with ease.", - "website": "https://docz.site" - }, - { - "name": "mdx-deck", - "slug": "mdx-deck", - "demo": "https://mdx-deck.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/mdx-deck.svg", - "tagline": "MDX Deck allows you to swiftly create React MDX-based presentation decks.", - "description": "An mdx-deck presentation template that includes a theme.", - "website": "https://github.com/jxnblk/mdx-deck" - }, - { - "name": "Aurelia", - "slug": "aurelia", - "demo": "https://aurelia.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/aurelia.svg", - "tagline": "Aurelia is an all-in-one framework for building web, desktop, and mobile applications.", - "description": "An Aurelia app, created with the Aurelia CLI.", - "website": "https://aurelia.io" - }, - { - "name": "VuePress", - "slug": "vuepress", - "demo": "https://vuepress.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/vuepress.png", - "tagline": "VuePress is the performant way to create static sites with Vue.js.", - "description": "A VuePress app, created with the VuePress CLI.", - "website": "https://vuepress.vuejs.org" - }, - { - "name": "Charge.js", - "slug": "charge", - "demo": "https://charge.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/chargejs.svg", - "tagline": "Charge is an opinionated, zero-config static site generator written in JavaScript.", - "description": "A Charge app to get you up and running." - }, - { - "name": "Riot.js", - "slug": "riot", - "demo": "https://riot.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/riot.svg", - "tagline": "Riot.js lets you build user interfaces with custom tags using simple and enjoyable syntax.", - "description": "A Riot app to get you up and running." - }, - { - "name": "Marko.js", - "slug": "marko", - "demo": "https://marko.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/marko.png", - "tagline": "Marko is a super fast UI library that makes building web apps fun.", - "description": "A Marko app, created with the Marko CLI." - }, - { - "name": "Mithril.js", - "slug": "mithril", - "demo": "https://mithril.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/mithriljs.svg", - "tagline": "Mithril is a lightweight modern web framework for that makes it easy to build SPAs.", - "description": "A Mithril app to get you up and running." - }, - { - "name": "Metalsmith", - "slug": "metalsmith", - "demo": "https://metalsmith.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/metalsmith.png", - "tagline": "Metalsmith is an extremely simple, extendable static site generator.", - "description": "A Metalsmith app, created using the static-site starter." - }, - { - "name": "HyperApp", - "slug": "hyperapp", - "demo": "https://hyperapp.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/hyperapp.svg", - "tagline": "HyperApp is a low-footprint framework for building web interfaces without a learning curve.", - "description": "A HyperApp app to get you up and running." - }, - { - "name": "Zola", - "slug": "zola", - "demo": "https://zola.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/zola.svg", - "tagline": "Zola is a one-stop static site engine for all of your static needs.", - "description": "A Zola site, created with the Zola CLI." - }, - { - "name": "Pelican", - "slug": "pelican", - "demo": "https://pelican.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/pelican.png", - "tagline": "Pelican is a versatile static site generator, written in Python.", - "description": "A Pelican site, created with the Pelican CLI." - }, - { - "name": "MkDocs", - "slug": "mkdocs", - "demo": "https://mkdocs.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/mkdocs.svg", - "tagline": "MkDocs is a fast, simple and downright gorgeous static site generator that's geared towards building project documentation.", - "description": "A MkDocs site, created with the MkDocs CLI." - }, - { - "name": "Assemble", - "slug": "assemble", - "demo": "https://assemble.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/assemble.svg", - "tagline": "A static site generator for Grunt.js and Yeoman, Assemble makes it dead simple to build modular sites and blogs.", - "description": "An Assemble site, created from the Assemble quickstart." - }, - { - "name": "Foundation", - "slug": "foundation", - "demo": "https://foundation.now-examples.now.sh", - "logo": "https://raw.githubusercontent.com/zeit/now/master/packages/frameworks/logos/foundation.svg", - "tagline": "Foundation is the most advanced responsive front-end framework in the world.", - "description": "A Foundation app, created with the Foundation CLI." - }, { "name": "Other", "slug": null,