Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
node-sass
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
楚学文
node-sass
Commits
21ac22e4
Commit
21ac22e4
authored
Dec 14, 2014
by
Adeel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
renderSync: Returns both css and map.
parent
9ce6de02
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
index.js
lib/index.js
+4
-1
api.js
test/api.js
+2
-2
No files found.
lib/index.js
View file @
21ac22e4
...
...
@@ -294,5 +294,8 @@ module.exports.middleware = function() {
endStats
(
options
,
options
.
stats
.
sourceMap
);
return
output
;
return
{
css
:
output
,
map
:
options
.
stats
.
sourceMap
};
};
test/api.js
View file @
21ac22e4
...
...
@@ -143,7 +143,7 @@ describe('api', function() {
it
(
'should compile sass to css'
,
function
(
done
)
{
var
src
=
read
(
fixture
(
'simple/index.scss'
),
'utf8'
);
var
expected
=
read
(
fixture
(
'simple/expected.css'
),
'utf8'
).
trim
();
var
css
=
sass
.
renderSync
({
data
:
src
}).
trim
();
var
css
=
sass
.
renderSync
({
data
:
src
}).
css
.
trim
();
assert
.
equal
(
css
,
expected
.
replace
(
/
\r\n
/g
,
'
\
n'
));
done
();
...
...
@@ -155,7 +155,7 @@ describe('api', function() {
var
css
=
sass
.
renderSync
({
data
:
src
,
indentedSyntax
:
true
}).
trim
();
}).
css
.
trim
();
assert
.
equal
(
css
,
expected
.
replace
(
/
\r\n
/g
,
'
\
n'
));
done
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment