Skip to content
This repository was archived by the owner on Dec 2, 2024. It is now read-only.

Commit 6342ab6

Browse files
authoredNov 1, 2023
[NO JIRA]: Clean up and remove cycle dependency (#56)
* [NO JIRA]: Clean up and remove cycle dependency * [NO JIRA]: Modify changelog --------- Co-authored-by: Aleksandr Sannikov <[email protected]>
1 parent e04ca7a commit 6342ab6

File tree

10 files changed

+42
-927
lines changed

10 files changed

+42
-927
lines changed
 

‎.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
/node_modules
22
npm-debug.log
33
*.css
4+
.idea

‎CHANGELOG.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,11 @@ All notable changes to this project will be documented in this file.
33

44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6-
76
## Unreleased
7+
- Remove dependency of backpack to break cycle dependency
8+
- Remove usage of sassFunctions as this is no longer needed after release of Backpack v31
9+
10+
## 1.0.0
811

912
## 1.0.0
1013

‎index.js

-3
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@ const sass = require('node-sass');
2828
const ora = require('ora');
2929
const { argv } = require('yargs');
3030

31-
const functions = require('@skyscanner/backpack-web/bpk-mixins/sass-functions');
32-
3331
const importer = require('./importer');
3432

3533
const getSassFiles = () =>
@@ -124,7 +122,6 @@ const worker = () =>
124122
{
125123
file,
126124
importer,
127-
functions,
128125
outputStyle: 'compressed',
129126
},
130127
(error, result) => {

‎package-lock.json

+31-900
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json

-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
"prettier": "prettier --config .prettierrc --write \"**/*.{js,jsx}\""
4646
},
4747
"dependencies": {
48-
"@skyscanner/backpack-web": "^29.6.0",
4948
"chokidar": "^3.5.3",
5049
"fast-glob": "^3.3.1",
5150
"find-parent-dir": "^0.3.1",

‎test/fail/test.scss

-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616
* limitations under the License.
1717
*/
1818

19-
@import '~@skyscanner/backpack-web/bpk-mixins/index';
20-
2119
.button {
2220
@include bpk-unknown;
2321
}

‎test/pass/_test.scss

+1-5
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,8 @@
1616
* limitations under the License.
1717
*/
1818

19-
@import '~@skyscanner/backpack-web/bpk-mixins/index';
19+
@import '~test';
2020

2121
.button {
2222
@include bpk-button;
2323
}
24-
25-
.icon {
26-
@include bpk-icon(flight, $bpk-color-sky-blue);
27-
}

‎test/pass/node_modules/test.scss

+3-6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎test/pass/test.scss

+1-5
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,8 @@
1616
* limitations under the License.
1717
*/
1818

19-
@import '~@skyscanner/backpack-web/bpk-mixins/index';
19+
@import '~test';
2020

2121
.button {
2222
@include bpk-button;
2323
}
24-
25-
.icon {
26-
@include bpk-icon(flight, $bpk-color-sky-blue);
27-
}

‎watcher.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ const sass = require('node-sass');
2626
const ora = require('ora');
2727
const { argv } = require('yargs');
2828

29-
const functions = require('@skyscanner/backpack-web/bpk-mixins/sass-functions');
30-
3129
const importer = require('./importer');
3230

3331
const getCssFileName = (name) => name.replace(/\.scss/, '.css');
@@ -43,15 +41,14 @@ const compileSass = async (file, spinner) => {
4341
const result = await renderSass({
4442
file,
4543
importer,
46-
functions,
4744
outputStyle: 'compressed',
4845
});
4946

5047
let prefixedContents;
5148

5249
if (argv.prefixComment) {
5350
try {
54-
const comment = `/*
51+
const comment = `/*
5552
${argv.prefixComment.replace(/^/gm, ' * ')}
5653
*/`;
5754
prefixedContents = [comment, result.css].join('\n');

0 commit comments

Comments
 (0)
This repository has been archived.