Repository: aexmachina/ember-cli-sass
Branch: master
Commit: 9fa7c7348179
Files: 44
Total size: 31.4 KB
Directory structure:
gitextract_x9o3wg_o/
├── .editorconfig
├── .ember-cli
├── .eslintignore
├── .eslintrc.js
├── .gitignore
├── .npmignore
├── .travis.yml
├── .watchmanconfig
├── CHANGELOG.md
├── LICENSE.md
├── README.md
├── RELEASE.md
├── app/
│ └── .gitkeep
├── blueprints/
│ └── ember-cli-sass/
│ └── index.js
├── config/
│ ├── ember-try.js
│ └── environment.js
├── ember-cli-build.js
├── index.js
├── package.json
├── testem.js
├── tests/
│ ├── .eslintrc.js
│ ├── acceptance/
│ │ └── app-test.js
│ ├── dummy/
│ │ ├── app/
│ │ │ ├── app.js
│ │ │ ├── components/
│ │ │ │ └── .gitkeep
│ │ │ ├── controllers/
│ │ │ │ └── .gitkeep
│ │ │ ├── helpers/
│ │ │ │ └── .gitkeep
│ │ │ ├── index.html
│ │ │ ├── models/
│ │ │ │ └── .gitkeep
│ │ │ ├── resolver.js
│ │ │ ├── router.js
│ │ │ ├── routes/
│ │ │ │ └── .gitkeep
│ │ │ ├── styles/
│ │ │ │ ├── app.scss
│ │ │ │ └── output-path.scss
│ │ │ └── templates/
│ │ │ ├── .gitkeep
│ │ │ └── application.hbs
│ │ ├── config/
│ │ │ ├── environment.js
│ │ │ └── targets.js
│ │ └── public/
│ │ ├── crossdomain.xml
│ │ └── robots.txt
│ ├── helpers/
│ │ └── .gitkeep
│ ├── index.html
│ ├── integration/
│ │ └── .gitkeep
│ └── test-helper.js
└── vendor/
└── .gitkeep
================================================
FILE CONTENTS
================================================
================================================
FILE: .editorconfig
================================================
# EditorConfig helps developers define and maintain consistent
# coding styles between different editors and IDEs
# editorconfig.org
root = true
[*]
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
indent_style = space
indent_size = 2
[*.hbs]
insert_final_newline = false
[*.{diff,md}]
trim_trailing_whitespace = false
================================================
FILE: .ember-cli
================================================
{
/**
Ember CLI sends analytics information by default. The data is completely
anonymous, but there are times when you might want to disable this behavior.
Setting `disableAnalytics` to true will prevent any data from being sent.
*/
"disableAnalytics": false
}
================================================
FILE: .eslintignore
================================================
# unconventional js
/blueprints/*/files/
/vendor/
# compiled output
/dist/
/tmp/
# misc
/coverage/
# ember-try
/.node_modules.ember-try/
================================================
FILE: .eslintrc.js
================================================
module.exports = {
root: true,
parserOptions: {
ecmaVersion: 2017,
sourceType: 'module'
},
plugins: [
'ember'
],
extends: [
'eslint:recommended',
'plugin:ember/recommended'
],
env: {
browser: true
},
rules: {
},
overrides: [
// node files
{
files: [
'ember-cli-build.js',
'index.js',
'testem.js',
'blueprints/*/index.js',
'config/**/*.js',
'tests/dummy/config/**/*.js'
],
excludedFiles: [
'addon/**',
'addon-test-support/**',
'app/**',
'tests/dummy/app/**'
],
parserOptions: {
sourceType: 'script',
ecmaVersion: 2015
},
env: {
browser: false,
node: true
},
plugins: ['node'],
rules: Object.assign({}, require('eslint-plugin-node').configs.recommended.rules, {
// add your custom rules and overrides for node files here
})
}
]
};
================================================
FILE: .gitignore
================================================
# See https://help.github.com/ignore-files/ for more about ignoring files.
# compiled output
/dist/
/tmp/
# dependencies
/node_modules/
# misc
/.sass-cache
/connect.lock
/coverage/
/libpeerconnection.log
/npm-debug.log*
/testem.log
/yarn-error.log
/.idea
# ember-try
/.node_modules.ember-try/
/package.json.ember-try
================================================
FILE: .npmignore
================================================
/config/ember-try.js
/dist
/tests
/tmp
**/.gitkeep
.editorconfig
.ember-cli
.gitignore
.eslintrc.js
.watchmanconfig
.travis.yml
ember-cli-build.js
testem.js
.idea
yarn.lock
# ember-try
.node_modules.ember-try/
package.json.ember-try
================================================
FILE: .travis.yml
================================================
---
language: node_js
node_js:
# we recommend testing addons with the same minimum supported node version as Ember CLI
# so that your addon works for all apps
- "10"
- "12"
sudo: false
dist: trusty
addons:
chrome: stable
cache:
directories:
- $HOME/.npm
- $HOME/.cache # includes bowers cache
env:
global:
# See https://git.io/vdao3 for details.
- JOBS=1
matrix:
# we recommend new addons test the current and previous LTS
# as well as latest stable release (bonus points to beta/canary)
- EMBER_TRY_SCENARIO=ember-release
- EMBER_TRY_SCENARIO=ember-beta
- EMBER_TRY_SCENARIO=ember-canary
- EMBER_TRY_SCENARIO=ember-default
matrix:
fast_finish: true
allow_failures:
- env: EMBER_TRY_SCENARIO=ember-canary
before_install:
- npm config set spin false
- npm install -g npm@4
- npm --version
install:
- npm install
script:
- npm run lint:js
# Usually, it's ok to finish the test scenario without reverting
# to the addon's original dependency state, skipping "cleanup".
- node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO --skip-cleanup
================================================
FILE: .watchmanconfig
================================================
{
"ignore_dirs": ["tmp", "dist"]
}
================================================
FILE: CHANGELOG.md
================================================
# Changelog
## v11.0.1 (2022-04-26)
#### :house: Internal
- [#221](https://github.com/adopted-ember-addons/ember-cli-sass/pull/221) chore: remove usage of bower ([@knownasilya](https://github.com/knownasilya))
- [#227](https://github.com/adopted-ember-addons/ember-cli-sass/pull/227) Bump tmpl from 1.0.4 to 1.0.5 ([@dependabot[bot]](https://github.com/apps/dependabot))
- [#226](https://github.com/adopted-ember-addons/ember-cli-sass/pull/226) Bump tar from 4.4.1 to 4.4.19 ([@dependabot[bot]](https://github.com/apps/dependabot))
- [#225](https://github.com/adopted-ember-addons/ember-cli-sass/pull/225) Bump mout from 1.1.0 to 1.2.3 ([@dependabot[bot]](https://github.com/apps/dependabot))
- [#224](https://github.com/adopted-ember-addons/ember-cli-sass/pull/224) Bump lodash from 4.17.10 to 4.17.21 ([@dependabot[bot]](https://github.com/apps/dependabot))
- [#223](https://github.com/adopted-ember-addons/ember-cli-sass/pull/223) Bump follow-redirects from 1.5.8 to 1.14.9 ([@dependabot[bot]](https://github.com/apps/dependabot))
- [#222](https://github.com/adopted-ember-addons/ember-cli-sass/pull/222) chore: add release-it and release v11 ([@knownasilya](https://github.com/knownasilya))
#### Committers: 1
- Ilya Radchenko ([@knownasilya](https://github.com/knownasilya))
## v11.0.0 (2022-04-25)
#### :boom: Breaking Change
- [#216](https://github.com/adopted-ember-addons/ember-cli-sass/pull/216) drop node support for < 10
#### :rocket: Enhancement
- [#220](https://github.com/adopted-ember-addons/ember-cli-sass/pull/220) Only rebuild on changes to (sass|scss|css) files ([@rohitpaulk](https://github.com/rohitpaulk))
#### Committers: 5
- Francesco Novy ([@mydea](https://github.com/mydea))
- Gabriel Csapo ([@gabrielcsapo](https://github.com/gabrielcsapo))
- Ilya Radchenko ([@knownasilya](https://github.com/knownasilya))
- Paul Kuruvilla ([@rohitpaulk](https://github.com/rohitpaulk))
- Simon Wade ([@simonexmachina](https://github.com/simonexmachina))
================================================
FILE: LICENSE.md
================================================
The MIT License (MIT)
Copyright (c) 2017 Simon Wade
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
================================================
FILE: README.md
================================================
# ember-cli-sass
[](https://www.npmjs.com/package/ember-cli-sass)
[](https://travis-ci.org/aexmachina/ember-cli-sass)
[](http://emberobserver.com/addons/ember-cli-sass)
[](https://david-dm.org/aexmachina/ember-cli-sass)
ember-cli-sass uses [Sass][] to preprocess your ember-cli app's styles, and provides support for source maps and include paths. It provides support for the common use case for Ember.js projects:
[sass]: https://sass-lang.com/
- Source maps by default in development
- Support for [`outputPaths` configuration](http://ember-cli.com/user-guide/#configuring-output-paths)
- Provides the ability to specify include paths
- Edit SASS in Chrome Dev Tools
## Installation
```
ember install ember-cli-sass
```
### Addon Development
If you want to use ember-cli-sass in an addon and you want to distribute the compiled CSS it must be installed as a `dependency` so that `addon/styles/addon.scss` is compiled into `dist/assets/vendor.css`. This can be done using:
```bash
npm install --save ember-cli-sass sass
```
## Using a different Sass implementation
By default this addon uses a distribution of [Dart Sass][] that is compiled to pure JavaScript. Dart Sass is the reference implementation for Sass, but it does provides significantly slower compilation times than LibSass (via `node-sass`).
[dart sass]: https://sass-lang.com/dart-sass
If you would like to use an alternative implementation (e.g. [`node-sass`](https://github.com/sass/node-sass)), you must
pass a Sass implementation to the `sassOptions` config property in `ember-cli-build.js` (or in `Brocfile.js` if you are
using an Ember CLI version older than 1.13):
```javascript
var nodeSass = require("node-sass");
var app = new EmberApp({
sassOptions: {
implementation: nodeSass,
},
});
```
By default this addon will compile `app/styles/app.scss` into `dist/assets/app.css` and produce
a source map for your delectation.
If you want more control, you can pass additional options to `sassOptions`:
- `includePaths`: an array of include paths
- `onlyIncluded`: true/false whether to use only what is in `app/styles` and `includePaths`. This may helps with performance, particularly when using NPM linked modules
- `sourceMap`: controls whether to generate sourceMaps, defaults to `true` in development. The sourceMap file will be saved to `options.outputFile + '.map'`
- `extension`: specifies the file extension for the input files, defaults to `scss`. Set to `sass` if you want to use `.sass` instead.
- `passthrough`: an optional hash of [broccoli-funnel](https://github.com/broccolijs/broccoli-funnel) configuration for files from the styles tree to be passed through to `dist`
- See [broccoli-sass-source-maps](https://github.com/aexmachina/broccoli-sass-source-maps) for a list of other supported options.
### Processing multiple files
If you need to process multiple files, it can be done by [configuring the output paths](http://ember-cli.com/user-guide/#configuring-output-paths) in your `ember-cli-build.js`:
```js
var app = new EmberApp({
outputPaths: {
app: {
css: {
app: "/assets/application-name.css",
"themes/alpha": "/assets/themes/alpha.css",
},
},
},
});
```
### Source Maps
Source maps work for reading with no configuration, but to edit the SASS in the Dev Tools
you need to configure your Workspace:
1. Open app.scss in Dev Tools (you can use ⌘P and search for "app.scss")
1. Right click in the Sources panel on the right of the Sources tab and
select _Add Folder to Workspace_
1. Select the root directory of your project
1. Right click on app.scss and select _Map to File System Resource..._
1. Select app.scss from your project directory
## Example
Install some SASS:
```shell
npm install --save foundation
```
Specify some include paths in your `ember-cli-build.js`:
```javascript
var app = new EmberApp({
sassOptions: {
includePaths: ["node_modules/foundation/scss"],
},
});
```
Import some deps into your app.scss:
```scss
@import "foundation"; /* import everything */
/* or just import the bits you need: @import 'foundation/functions'; */
```
## Addon Usage
To compile SASS within an ember-cli addon, there are a few additional steps:
1. Include your styles in `addon/styles/addon.scss`.
2. Ensure you've installed `ember-cli-sass` and either `sass` or `node-sass`
under `dependencies` in your `package.json`.
3. Define an `included` function in your addon's `index.js`:
```js
// in your index.js
module.exports = {
name: "my-addon",
included: function (/* app */) {
this._super.included.apply(this, arguments);
},
};
```
If you omit this step, it will throw the following error:
```
Cannot read property 'sassOptions' of undefined
TypeError: Cannot read property 'sassOptions' of undefined
at Class.module.exports.sassOptions (~/my-plugin/node_modules/ember-cli-sass/index.js:43:48)
```
4. Make sure your dummy app contains an `app.scss`
5. If you run `ember build dist`, your styles from `addon/styles/addon.scss`
should appear correctly in `dist/assets/vendor.css`
## Alternative Addon Usage
As an alternative to the above, some addons may choose to allow their SASS to be used in
the parent app, rather than the compiled CSS. This has the advantage of easily allowing
users to use and override your SASS. The steps for this setup are as follows:
1. Instead of including your styles in `addon/styles/addon.scss`, place them in
`app/styles/your-addon-name.scss`. Document that your user can now add
`@import 'your-addon-name';` to their `app.scss` file. In the lines before this import
they can choose to override any variables your addon marks with
[default](http://sass-lang.com/documentation/file.SASS_REFERENCE.html#variable_defaults_).
2. Ensure steps 2, 3 and 4 are completed as per the standard addon usage section above.
## Usage within in-repo addon and in-repo engine
To re-use SASS definitions from an in-repo-addon within an in-repo-engine, you
need to add the in-repo addons' path to the `includePaths`. So basically if you
have a directory layout like this (where `common` is an in-repo addon):
```
app
└── lib
├── my-in-repo-engine
│ ├── addon
│ │ └── styles
│ │ └── addon.scss
│ └── index.js
└── common
└── app
└── styles
└── common
└── vars.scss
```
The `app/lib/my-in-repo-engine/index.js` should look like this:
```js
const EngineAddon = require('ember-engines/lib/engine-addon');
module.exports = EngineAddon.extend({
sassOptions: {
includePaths: ['lib/common/app/styles']
},
...
};
```
and then you can include the definitions inside the engines SASS files via:
```scss
@import "common/vars";
```
## Changelog
- v9.0.0 Added support for multiple sass implementations (e.g. Dart Sass, LibSass, etc.) The default Sass implementation is [Dart Sass](https://sass-lang.com/dart-sass), which is now the [reference implementation of Sass](http://sass.logdown.com/posts/1022316-announcing-dart-sass). This provides significantly slower compilation times than node-sass, but you can see instructions above if you'd like to continue using node-sass.
================================================
FILE: RELEASE.md
================================================
# Release Process
Releases are mostly automated using
[release-it](https://github.com/release-it/release-it/) and
[lerna-changelog](https://github.com/lerna/lerna-changelog/).
## Preparation
Since the majority of the actual release process is automated, the primary
remaining task prior to releasing is confirming that all pull requests that
have been merged since the last release have been labeled with the appropriate
`lerna-changelog` labels and the titles have been updated to ensure they
represent something that would make sense to our users. Some great information
on why this is important can be found at
[keepachangelog.com](https://keepachangelog.com/en/1.0.0/), but the overall
guiding principle here is that changelogs are for humans, not machines.
When reviewing merged PR's the labels to be used are:
* breaking - Used when the PR is considered a breaking change.
* enhancement - Used when the PR adds a new feature or enhancement.
* bug - Used when the PR fixes a bug included in a previous release.
* documentation - Used when the PR adds or updates documentation.
* internal - Used for internal changes that still require a mention in the
changelog/release notes.
## Release
Once the prep work is completed, the actual release is straight forward:
* First, ensure that you have installed your projects dependencies:
```sh
npm install
```
* Second, ensure that you have obtained a
[GitHub personal access token][generate-token] with the `repo` scope (no
other permissions are needed). Make sure the token is available as the
`GITHUB_AUTH` environment variable.
For instance:
```bash
export GITHUB_AUTH=abc123def456
```
[generate-token]: https://github.com/settings/tokens/new?scopes=repo&description=GITHUB_AUTH+env+variable
* And last (but not least 😁) do your release.
```sh
npx release-it
```
[release-it](https://github.com/release-it/release-it/) manages the actual
release process. It will prompt you to to choose the version number after which
you will have the chance to hand tweak the changelog to be used (for the
`CHANGELOG.md` and GitHub release), then `release-it` continues on to tagging,
pushing the tag and commits, etc.
================================================
FILE: app/.gitkeep
================================================
================================================
FILE: blueprints/ember-cli-sass/index.js
================================================
/* eslint-env node */
module.exports = {
normalizeEntityName() {}, // no-op since we're just adding dependencies
afterInstall() {
return this.addPackageToProject('sass');
}
};
================================================
FILE: config/ember-try.js
================================================
'use strict';
const getChannelURL = require('ember-source-channel-url');
module.exports = function() {
return Promise.all([
getChannelURL('release'),
getChannelURL('beta'),
getChannelURL('canary')
]).then((urls) => {
return {
scenarios: [
{
name: 'ember-lts-2.12',
npm: {
devDependencies: {
'ember-source': '~2.12.0'
}
}
},
{
name: 'ember-lts-2.16',
npm: {
devDependencies: {
'ember-source': '~2.16.0'
}
}
},
{
name: 'ember-lts-2.18',
npm: {
devDependencies: {
'ember-source': '~2.18.0'
}
}
},
{
name: 'ember-release',
npm: {
devDependencies: {
'ember-source': urls[0]
}
}
},
{
name: 'ember-beta',
npm: {
devDependencies: {
'ember-source': urls[1]
}
}
},
{
name: 'ember-canary',
npm: {
devDependencies: {
'ember-source': urls[2]
}
}
},
{
name: 'ember-default',
npm: {
devDependencies: {}
}
}
]
};
});
};
================================================
FILE: config/environment.js
================================================
/* eslint-env node */
'use strict';
module.exports = function(/* environment, appConfig */) {
return { };
};
================================================
FILE: ember-cli-build.js
================================================
/* eslint-env node */
"use strict";
const EmberAddon = require("ember-cli/lib/broccoli/ember-addon");
const sass = require("sass");
module.exports = function (defaults) {
let app = new EmberAddon(defaults, {
outputPaths: {
app: {
css: {
app: "/assets/dummy.css",
"output-path": "/assets/output-path.css",
},
},
},
sassOptions: {
implementation: sass,
includePaths: ["node_modules/spinkit/scss"],
},
});
/*
This build file specifies the options for the dummy test app of this
addon, located in `/tests/dummy`
This build file does *not* influence how the addon or the app using it
behave. You most likely want to be modifying `./index.js` or app's build file
*/
return app.toTree();
};
================================================
FILE: index.js
================================================
'use strict';
/* eslint-env node */
var SassCompilerFactory = require('broccoli-sass-source-maps');
var path = require('path');
var VersionChecker = require('ember-cli-version-checker');
var Funnel = require('broccoli-funnel');
var mergeTrees = require('broccoli-merge-trees');
function SASSPlugin(optionsFn) {
this.name = 'ember-cli-sass';
this.optionsFn = optionsFn;
this.ext = ['scss', 'sass'];
}
SASSPlugin.prototype.toTree = function(tree, inputPath, outputPath, inputOptions) {
var options = Object.assign({}, this.optionsFn(), inputOptions);
var inputTrees = [
new Funnel(tree, {
include: [options.onlyIncluded ? 'app/styles/**/*' : /\.(scss|sass|css)$/],
annotation: 'Funnel (styles)'
})
];
if (options.includePaths) {
inputTrees = inputTrees.concat(options.includePaths);
}
if (!options.implementation) {
try {
// eslint-disable-next-line node/no-unpublished-require
options.implementation = require('sass');
} catch (e) {
var error = new Error(
'Could not find the default SASS implementation. Run the default blueprint:\n' +
' ember g ember-cli-sass\n' +
'Or install an implementation such as "node-sass" and add an implementation option. For example:\n' +
' sassOptions: {implementation: require("node-sass")}');
error.type = 'Sass Plugin Error';
throw error;
}
}
var SassCompiler = SassCompilerFactory(options.implementation);
var ext = options.extension || 'scss';
var paths = options.outputPaths;
var trees = Object.keys(paths).map(function(file) {
var input = path.join(inputPath, file + '.' + ext);
var output = paths[file];
return new SassCompiler(inputTrees, input, output, options);
});
if (options.passthrough) {
trees.push(new Funnel(tree, options.passthrough));
}
return mergeTrees(trees);
};
module.exports = {
name: 'ember-cli-sass',
shouldSetupRegistryInIncluded: function() {
let checker = new VersionChecker(this);
return !checker.for('ember-cli').isAbove('0.2.0');
},
sassOptions: function () {
var env = process.env.EMBER_ENV;
var envConfig = this.project.config(env).sassOptions;
var app = this.app;
var parent = this.parent;
var hostApp = typeof this._findHost === 'function' ? this._findHost() : undefined;
// *Either* use the options for an addon which is consuming this, *or* for
// an app which is consuming this, but never *both* at the same time. The
// special case here is when testing an addon.
// In lazy loading engines, the host might be different from the parent, so we fall back to that one
var options = (app && app.options && app.options.sassOptions)
|| (parent && parent.options && parent.options.sassOptions)
|| (hostApp && hostApp.options && hostApp.options.sassOptions)
|| {};
if (envConfig) {
console.warn("Deprecation warning: sassOptions should be moved to your ember-cli-build"); // eslint-disable-line
Object.assign(options, envConfig);
}
if ((options.sourceMap === undefined) && (env == 'development')) {
options.sourceMap = true;
}
if (options.sourceMap || options.sourceMapEmbed) {
// we need to embed the sourcesContent in the source map until libsass has better support for broccoli-sass
options.sourceMapContents = true;
}
options.outputFile = options.outputFile || this.project.name() + '.css';
options.sourceMapRoot = path.join(this.project.root, 'app/styles');
return options;
},
setupPreprocessorRegistry: function(type, registry) {
registry.add('css', new SASSPlugin(this.sassOptions.bind(this)));
// prevent conflict with broccoli-sass if it's installed
if (registry.remove) registry.remove('css', 'broccoli-sass');
},
included: function included(app) {
this._super.included.apply(this, arguments);
// see: https://github.com/ember-cli/ember-cli/issues/3718
if (typeof app.import !== 'function' && app.app) {
app = app.app;
}
this.app = app;
if (this.shouldSetupRegistryInIncluded()) {
this.setupPreprocessorRegistry('parent', app.registry);
}
}
};
================================================
FILE: package.json
================================================
{
"name": "ember-cli-sass",
"version": "11.0.1",
"description": "Use Sass to preprocess your ember-cli app's files, with support for sourceMaps and include paths",
"keywords": [
"ember-addon",
"sass"
],
"homepage": "https://github.com/adopted-ember-addons/ember-cli-sass",
"bugs": {
"url": "https://github.com/adopted-ember-addons/ember-cli-sass/issues"
},
"repository": {
"type": "git",
"url": "git://github.com/adopted-ember-addons/ember-cli-sass.git"
},
"license": "MIT",
"author": "@aexmachina",
"directories": {
"doc": "doc",
"test": "tests"
},
"scripts": {
"build": "ember build",
"lint:js": "eslint .",
"start": "ember serve",
"test": "ember test",
"test:all": "ember try:each"
},
"dependencies": {
"broccoli-funnel": "^2.0.1",
"broccoli-merge-trees": "^3.0.1",
"broccoli-sass-source-maps": "^4.0.0",
"ember-cli-version-checker": "^2.1.0"
},
"devDependencies": {
"broccoli-asset-rev": "^2.7.0",
"broccoli-clean-css": "^1.1.0",
"ember-cli": "^3.4.1",
"ember-cli-babel": "^6.6.0",
"ember-cli-dependency-checker": "^2.0.0",
"ember-cli-eslint": "^4.2.1",
"ember-cli-htmlbars": "^2.0.1",
"ember-cli-htmlbars-inline-precompile": "^1.0.3",
"ember-cli-inject-live-reload": "^1.4.1",
"ember-cli-qunit": "^4.3.2",
"ember-cli-shims": "^1.2.0",
"ember-cli-sri": "^2.1.0",
"ember-cli-uglify": "^2.0.0",
"ember-disable-prototype-extensions": "^1.1.2",
"ember-export-application-global": "^2.0.0",
"ember-load-initializers": "^1.1.0",
"ember-maybe-import-regenerator": "^0.1.6",
"ember-resolver": "^4.0.0",
"ember-source": "^3.4.0",
"ember-source-channel-url": "^1.0.1",
"ember-try": "^1.0.0",
"eslint-plugin-ember": "^5.0.0",
"eslint-plugin-node": "^6.0.1",
"loader.js": "^4.2.3",
"qunit-dom": "^0.7.1",
"release-it": "^14.2.1",
"release-it-lerna-changelog": "^3.1.0",
"sass": "^1.51.0",
"spinkit": "^1.2.5"
},
"engines": {
"node": ">= 10.*"
},
"publishConfig": {
"registry": "https://registry.npmjs.org"
},
"ember-addon": {
"configPath": "tests/dummy/config"
},
"release-it": {
"plugins": {
"release-it-lerna-changelog": {
"infile": "CHANGELOG.md",
"launchEditor": false
}
},
"git": {
"tagName": "v${version}"
},
"github": {
"release": true,
"tokenRef": "GITHUB_AUTH"
}
}
}
================================================
FILE: testem.js
================================================
/* eslint-env node */
module.exports = {
test_page: 'tests/index.html?hidepassed',
disable_watching: true,
launch_in_ci: [
'Chrome'
],
launch_in_dev: [
'Chrome'
],
browser_args: {
Chrome: {
ci: [
// --no-sandbox is needed when running Chrome inside a container
process.env.CI ? '--no-sandbox' : null,
'--headless',
'--disable-gpu',
'--disable-dev-shm-usage',
'--disable-software-rasterizer',
'--mute-audio',
'--remote-debugging-port=0',
'--window-size=1440,900'
].filter(Boolean)
}
}
};
================================================
FILE: tests/.eslintrc.js
================================================
module.exports = {
env: {
embertest: true
}
};
================================================
FILE: tests/acceptance/app-test.js
================================================
import { module, test } from 'qunit';
import { visit, find } from '@ember/test-helpers';
import { setupApplicationTest } from 'ember-qunit';
let getCSS = function(el, prop) {
let style = window.getComputedStyle(el);
return style.getPropertyValue(prop);
}
module('Acceptance | app', function(hooks) {
setupApplicationTest(hooks);
test('app.scss is loaded', async function(assert) {
await visit('/');
assert.ok(getCSS(find('#app-css'), 'font-family'));
});
test('outputPaths are supported', async function(assert) {
await visit('/');
assert.ok(getCSS(find('#output-path-css'), 'font-family'));
});
test('includePaths are supported', async function(assert) {
await visit('/');
assert.ok(getCSS(find('#include-path-css'), 'animation-duration'));
});
test('addons can inject styles', async function(assert) {
await visit('/');
assert.ok(getCSS(find('h1'), 'font-family'));
});
});
================================================
FILE: tests/dummy/app/app.js
================================================
import Application from '@ember/application';
import Resolver from './resolver';
import loadInitializers from 'ember-load-initializers';
import config from './config/environment';
const App = Application.extend({
modulePrefix: config.modulePrefix,
podModulePrefix: config.podModulePrefix,
Resolver
});
loadInitializers(App, config.modulePrefix);
export default App;
================================================
FILE: tests/dummy/app/components/.gitkeep
================================================
================================================
FILE: tests/dummy/app/controllers/.gitkeep
================================================
================================================
FILE: tests/dummy/app/helpers/.gitkeep
================================================
================================================
FILE: tests/dummy/app/index.html
================================================
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Dummy</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
{{content-for "head"}}
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/vendor.css">
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/dummy.css">
{{content-for "head-footer"}}
</head>
<body>
{{content-for "body"}}
<script src="{{rootURL}}assets/vendor.js"></script>
<script src="{{rootURL}}assets/dummy.js"></script>
{{content-for "body-footer"}}
</body>
</html>
================================================
FILE: tests/dummy/app/models/.gitkeep
================================================
================================================
FILE: tests/dummy/app/resolver.js
================================================
import Resolver from 'ember-resolver';
export default Resolver;
================================================
FILE: tests/dummy/app/router.js
================================================
import EmberRouter from '@ember/routing/router';
import config from './config/environment';
const Router = EmberRouter.extend({
location: config.locationType,
rootURL: config.rootURL
});
Router.map(function() {
});
export default Router;
================================================
FILE: tests/dummy/app/routes/.gitkeep
================================================
================================================
FILE: tests/dummy/app/styles/app.scss
================================================
@import 'spinkit';
#app-css {
font-family: 'ember-cli-sass';
}
================================================
FILE: tests/dummy/app/styles/output-path.scss
================================================
#output-path-css {
font-family: 'ember-cli-sass';
}
================================================
FILE: tests/dummy/app/templates/.gitkeep
================================================
================================================
FILE: tests/dummy/app/templates/application.hbs
================================================
<h1>ember-cli-sass test</h1>
<div id='app-css'></div>
<div id='output-path-css'></div>
<div id='include-path-css' class='sk-rotating-plane'></div>
================================================
FILE: tests/dummy/config/environment.js
================================================
'use strict';
module.exports = function(environment) {
let ENV = {
modulePrefix: 'dummy',
environment,
rootURL: '/',
locationType: 'auto',
EmberENV: {
FEATURES: {
// Here you can enable experimental features on an ember canary build
// e.g. 'with-controller': true
},
EXTEND_PROTOTYPES: {
// Prevent Ember Data from overriding Date.parse.
Date: false
}
},
APP: {
// Here you can pass flags/options to your application instance
// when it is created
}
};
if (environment === 'development') {
// ENV.APP.LOG_RESOLVER = true;
// ENV.APP.LOG_ACTIVE_GENERATION = true;
// ENV.APP.LOG_TRANSITIONS = true;
// ENV.APP.LOG_TRANSITIONS_INTERNAL = true;
// ENV.APP.LOG_VIEW_LOOKUPS = true;
}
if (environment === 'test') {
// Testem prefers this...
ENV.locationType = 'none';
// keep test console output quieter
ENV.APP.LOG_ACTIVE_GENERATION = false;
ENV.APP.LOG_VIEW_LOOKUPS = false;
ENV.APP.rootElement = '#ember-testing';
ENV.APP.autoboot = false;
}
if (environment === 'production') {
// here you can enable a production-specific feature
}
return ENV;
};
================================================
FILE: tests/dummy/config/targets.js
================================================
'use strict';
const browsers = [
'last 1 Chrome versions',
'last 1 Firefox versions',
'last 1 Safari versions'
];
const isCI = !!process.env.CI;
const isProduction = process.env.EMBER_ENV === 'production';
if (isCI || isProduction) {
browsers.push('ie 11');
}
module.exports = {
browsers
};
================================================
FILE: tests/dummy/public/crossdomain.xml
================================================
<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
<!-- Read this: www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html -->
<!-- Most restrictive policy: -->
<site-control permitted-cross-domain-policies="none"/>
<!-- Least restrictive policy: -->
<!--
<site-control permitted-cross-domain-policies="all"/>
<allow-access-from domain="*" to-ports="*" secure="false"/>
<allow-http-request-headers-from domain="*" headers="*" secure="false"/>
-->
</cross-domain-policy>
================================================
FILE: tests/dummy/public/robots.txt
================================================
# http://www.robotstxt.org
User-agent: *
Disallow:
================================================
FILE: tests/helpers/.gitkeep
================================================
================================================
FILE: tests/index.html
================================================
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Dummy Tests</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
{{content-for "head"}}
{{content-for "test-head"}}
<link rel="stylesheet" href="{{rootURL}}assets/vendor.css">
<link rel="stylesheet" href="{{rootURL}}assets/dummy.css">
<link rel="stylesheet" href="{{rootURL}}assets/output-path.css">
<link rel="stylesheet" href="{{rootURL}}assets/test-support.css">
{{content-for "head-footer"}}
{{content-for "test-head-footer"}}
</head>
<body>
{{content-for "body"}}
{{content-for "test-body"}}
<script src="/testem.js" integrity=""></script>
<script src="{{rootURL}}assets/vendor.js"></script>
<script src="{{rootURL}}assets/test-support.js"></script>
<script src="{{rootURL}}assets/dummy.js"></script>
<script src="{{rootURL}}assets/tests.js"></script>
{{content-for "body-footer"}}
{{content-for "test-body-footer"}}
</body>
</html>
================================================
FILE: tests/integration/.gitkeep
================================================
================================================
FILE: tests/test-helper.js
================================================
import Application from '../app';
import config from '../config/environment';
import { setApplication } from '@ember/test-helpers';
import { start } from 'ember-qunit';
setApplication(Application.create(config.APP));
start();
================================================
FILE: vendor/.gitkeep
================================================
gitextract_x9o3wg_o/
├── .editorconfig
├── .ember-cli
├── .eslintignore
├── .eslintrc.js
├── .gitignore
├── .npmignore
├── .travis.yml
├── .watchmanconfig
├── CHANGELOG.md
├── LICENSE.md
├── README.md
├── RELEASE.md
├── app/
│ └── .gitkeep
├── blueprints/
│ └── ember-cli-sass/
│ └── index.js
├── config/
│ ├── ember-try.js
│ └── environment.js
├── ember-cli-build.js
├── index.js
├── package.json
├── testem.js
├── tests/
│ ├── .eslintrc.js
│ ├── acceptance/
│ │ └── app-test.js
│ ├── dummy/
│ │ ├── app/
│ │ │ ├── app.js
│ │ │ ├── components/
│ │ │ │ └── .gitkeep
│ │ │ ├── controllers/
│ │ │ │ └── .gitkeep
│ │ │ ├── helpers/
│ │ │ │ └── .gitkeep
│ │ │ ├── index.html
│ │ │ ├── models/
│ │ │ │ └── .gitkeep
│ │ │ ├── resolver.js
│ │ │ ├── router.js
│ │ │ ├── routes/
│ │ │ │ └── .gitkeep
│ │ │ ├── styles/
│ │ │ │ ├── app.scss
│ │ │ │ └── output-path.scss
│ │ │ └── templates/
│ │ │ ├── .gitkeep
│ │ │ └── application.hbs
│ │ ├── config/
│ │ │ ├── environment.js
│ │ │ └── targets.js
│ │ └── public/
│ │ ├── crossdomain.xml
│ │ └── robots.txt
│ ├── helpers/
│ │ └── .gitkeep
│ ├── index.html
│ ├── integration/
│ │ └── .gitkeep
│ └── test-helper.js
└── vendor/
└── .gitkeep
SYMBOL INDEX (3 symbols across 2 files)
FILE: blueprints/ember-cli-sass/index.js
method normalizeEntityName (line 3) | normalizeEntityName() {}
method afterInstall (line 5) | afterInstall() {
FILE: index.js
function SASSPlugin (line 9) | function SASSPlugin(optionsFn) {
Condensed preview — 44 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (36K chars).
[
{
"path": ".editorconfig",
"chars": 368,
"preview": "# EditorConfig helps developers define and maintain consistent\n# coding styles between different editors and IDEs\n# edit"
},
{
"path": ".ember-cli",
"chars": 280,
"preview": "{\n /**\n Ember CLI sends analytics information by default. The data is completely\n anonymous, but there are times "
},
{
"path": ".eslintignore",
"chars": 141,
"preview": "# unconventional js\n/blueprints/*/files/\n/vendor/\n\n# compiled output\n/dist/\n/tmp/\n\n\n# misc\n/coverage/\n\n# ember-try\n/.nod"
},
{
"path": ".eslintrc.js",
"chars": 977,
"preview": "module.exports = {\n root: true,\n parserOptions: {\n ecmaVersion: 2017,\n sourceType: 'module'\n },\n plugins: [\n "
},
{
"path": ".gitignore",
"chars": 321,
"preview": "# See https://help.github.com/ignore-files/ for more about ignoring files.\n\n# compiled output\n/dist/\n/tmp/\n\n# dependenci"
},
{
"path": ".npmignore",
"chars": 234,
"preview": "/config/ember-try.js\n/dist\n/tests\n/tmp\n**/.gitkeep\n.editorconfig\n.ember-cli\n.gitignore\n.eslintrc.js\n.watchmanconfig\n.tra"
},
{
"path": ".travis.yml",
"chars": 1124,
"preview": "---\nlanguage: node_js\nnode_js:\n # we recommend testing addons with the same minimum supported node version as Ember CLI"
},
{
"path": ".watchmanconfig",
"chars": 37,
"preview": "{\n \"ignore_dirs\": [\"tmp\", \"dist\"]\n}\n"
},
{
"path": "CHANGELOG.md",
"chars": 1979,
"preview": "# Changelog\n\n## v11.0.1 (2022-04-26)\n\n#### :house: Internal\n\n- [#221](https://github.com/adopted-ember-addons/ember-cli-"
},
{
"path": "LICENSE.md",
"chars": 1077,
"preview": "The MIT License (MIT)\n\nCopyright (c) 2017 Simon Wade\n\nPermission is hereby granted, free of charge, to any person obtain"
},
{
"path": "README.md",
"chars": 7528,
"preview": "# ember-cli-sass\n\n[](https://www.npmjs.com/package/ember-cli-"
},
{
"path": "RELEASE.md",
"chars": 2186,
"preview": "# Release Process\n\nReleases are mostly automated using\n[release-it](https://github.com/release-it/release-it/) and\n[lern"
},
{
"path": "app/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "blueprints/ember-cli-sass/index.js",
"chars": 187,
"preview": "/* eslint-env node */\nmodule.exports = {\n normalizeEntityName() {}, // no-op since we're just adding dependencies\n\n af"
},
{
"path": "config/ember-try.js",
"chars": 1407,
"preview": "\n'use strict';\n\nconst getChannelURL = require('ember-source-channel-url');\n\nmodule.exports = function() {\n return Promi"
},
{
"path": "config/environment.js",
"chars": 112,
"preview": "/* eslint-env node */\n'use strict';\n\nmodule.exports = function(/* environment, appConfig */) {\n return { };\n};\n"
},
{
"path": "ember-cli-build.js",
"chars": 790,
"preview": "/* eslint-env node */\n\"use strict\";\n\nconst EmberAddon = require(\"ember-cli/lib/broccoli/ember-addon\");\nconst sass = requ"
},
{
"path": "index.js",
"chars": 4201,
"preview": "'use strict';\n/* eslint-env node */\nvar SassCompilerFactory = require('broccoli-sass-source-maps');\nvar path = require('"
},
{
"path": "package.json",
"chars": 2486,
"preview": "{\n \"name\": \"ember-cli-sass\",\n \"version\": \"11.0.1\",\n \"description\": \"Use Sass to preprocess your ember-cli app's files"
},
{
"path": "testem.js",
"chars": 603,
"preview": "/* eslint-env node */\nmodule.exports = {\n test_page: 'tests/index.html?hidepassed',\n disable_watching: true,\n launch_"
},
{
"path": "tests/.eslintrc.js",
"chars": 55,
"preview": "module.exports = {\n env: {\n embertest: true\n }\n};\n"
},
{
"path": "tests/acceptance/app-test.js",
"chars": 947,
"preview": "import { module, test } from 'qunit';\nimport { visit, find } from '@ember/test-helpers';\nimport { setupApplicationTest }"
},
{
"path": "tests/dummy/app/app.js",
"chars": 375,
"preview": "import Application from '@ember/application';\nimport Resolver from './resolver';\nimport loadInitializers from 'ember-loa"
},
{
"path": "tests/dummy/app/components/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/dummy/app/controllers/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/dummy/app/helpers/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/dummy/app/index.html",
"chars": 684,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"utf-8\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\">\n "
},
{
"path": "tests/dummy/app/models/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/dummy/app/resolver.js",
"chars": 65,
"preview": "import Resolver from 'ember-resolver';\n\nexport default Resolver;\n"
},
{
"path": "tests/dummy/app/router.js",
"chars": 245,
"preview": "import EmberRouter from '@ember/routing/router';\nimport config from './config/environment';\n\nconst Router = EmberRouter."
},
{
"path": "tests/dummy/app/routes/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/dummy/app/styles/app.scss",
"chars": 66,
"preview": "@import 'spinkit';\n\n#app-css {\n font-family: 'ember-cli-sass';\n}\n"
},
{
"path": "tests/dummy/app/styles/output-path.scss",
"chars": 54,
"preview": "#output-path-css {\n font-family: 'ember-cli-sass';\n}\n"
},
{
"path": "tests/dummy/app/templates/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/dummy/app/templates/application.hbs",
"chars": 147,
"preview": "<h1>ember-cli-sass test</h1>\n<div id='app-css'></div>\n<div id='output-path-css'></div>\n<div id='include-path-css' class="
},
{
"path": "tests/dummy/config/environment.js",
"chars": 1225,
"preview": "'use strict';\n\nmodule.exports = function(environment) {\n let ENV = {\n modulePrefix: 'dummy',\n environment,\n ro"
},
{
"path": "tests/dummy/config/targets.js",
"chars": 305,
"preview": "'use strict';\n\nconst browsers = [\n 'last 1 Chrome versions',\n 'last 1 Firefox versions',\n 'last 1 Safari versions'\n];"
},
{
"path": "tests/dummy/public/crossdomain.xml",
"chars": 585,
"preview": "<?xml version=\"1.0\"?>\n<!DOCTYPE cross-domain-policy SYSTEM \"http://www.adobe.com/xml/dtds/cross-domain-policy.dtd\">\n<cro"
},
{
"path": "tests/dummy/public/robots.txt",
"chars": 51,
"preview": "# http://www.robotstxt.org\nUser-agent: *\nDisallow:\n"
},
{
"path": "tests/helpers/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/index.html",
"chars": 1114,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"utf-8\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\">\n "
},
{
"path": "tests/integration/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "tests/test-helper.js",
"chars": 228,
"preview": "import Application from '../app';\nimport config from '../config/environment';\nimport { setApplication } from '@ember/tes"
},
{
"path": "vendor/.gitkeep",
"chars": 0,
"preview": ""
}
]
About this extraction
This page contains the full source code of the aexmachina/ember-cli-sass GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 44 files (31.4 KB), approximately 9.5k tokens, and a symbol index with 3 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.
Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.