[![Latest NPM release][npm-badge]][npm-badge-url]
[![TravisCI Build Status][travis-badge-url]][travis-project-url]
[![CircleCI Build Status][circle-badge]][circle-badge-url]
[![Test Coverage][coveralls-badge]][coveralls-badge-url]
[![Code Climate][codeclimate-badge]][codeclimate-badge-url]
[![Ember Observer Score][ember-observer-badge]][ember-observer-badge-url]
[![License][license-badge]][license-badge-url]
[![Dependencies][dependencies-badge]][dependencies-badge-url]
[![Dev Dependencies][devDependencies-badge]][devDependencies-badge-url]
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @import "../variables/_spacing.css"; | |
| /* | |
| * SPACING UTILITIES | |
| * | |
| * Utilities for setting padding and margin. | |
| * | |
| * Legend: | |
| * | |
| * Rules: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| :root { | |
| /* -------------------------- Ins -------------------------- */ | |
| --easing__ease-in-sine: cubic-bezier(0.470, 0.000, 0.745, 0.715); | |
| --easing__ease-in-quad: cubic-bezier(0.550, 0.085, 0.680, 0.530); | |
| --easing__ease-in-cubic: cubic-bezier(0.55, 0.055, 0.675, 0.19); | |
| --easing__ease-in-cubic--sluggish: cubic-bezier(0.470, 0.020, 1.000, 0.570); | |
| --easing__ease-in-quartic: cubic-bezier(0.895, 0.030, 0.685, 0.220); | |
| --easing__ease-in-quint: cubic-bezier(0.755, 0.050, 0.855, 0.060); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import Ember from 'ember'; | |
| export default Ember.Component.extend({ | |
| tagName: 'img', | |
| attributeBindings: ['imagePath:src', 'imageName:alt'], | |
| imagePath: '', | |
| imageName: '' | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export default function range(_start, _end) { | |
| // If only one argument (n) is passed, we generate a range from 0 to n. | |
| const start = typeof _end === 'undefined' ? 0 : _start; | |
| const end = typeof _end === 'undefined' ? _start : _end; | |
| // "direction" multiplier to produce a decreasing sequence if `start` is greater than `end`. | |
| const direction = start > end ? -1 : 1; | |
| const size = Math.abs(end - start) + 1; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <cstdlib> | |
| int boundedRandom(int min, int max) { | |
| static const double randFraction = 1.0 / (static_cast<double>(RAND_MAX)); | |
| int offset = (max - min + 1) * (rand() * randFraction); | |
| return min + offset; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| :root { | |
| /* --------------- THEME COLORS --------------- */ | |
| --theme-color__primary: #9D6D45; | |
| --theme-color__primary--light: #AA764B; | |
| --theme-color__primary--dark: #1D140D; | |
| --theme-color__supporting-1: #56ee9d; | |
| --theme-color__supporting-1--light: #99FBC7; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Byte-compiled / optimized / DLL files | |
| __pycache__/ | |
| *.py[cod] | |
| *$py.class | |
| # C extensions | |
| *.so | |
| # Distribution / packaging | |
| .Python |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const { floor, random } = Math; | |
| function boundedRandom(min, max) { | |
| const spread = max - min; | |
| return min + floor(random() * spread); | |
| } |
This document is meant to be a brief "checklist" of things to setup for your Ember addon when beginning development in order to have the best possible architecture and workflow out of the gate. For more comprehensive material, the following are bookshelf-caliber:
-
Ember Addon Secrets - Written around the Ember 2.6 era, this article takes a much deeper dive into several of the topics mentioned here.
NewerOlder