Show options in test title (#7785)

* Show options in test title

* Update snapshots
This commit is contained in:
fisker Cheung authored and GitHub committed 2020-04-18 16:09:07 +03:00
1 parent 34f77e5649
commit be56c725c0
143 files changed
+29541 -29524

No files matched your search

@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`test.component.ts format 1`] = `
exports[`test.component.ts - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
@@ -47,7 +47,7 @@ class TestComponent {}
================================================================================
`;
exports[`test.component.ts format 2`] = `
exports[`test.component.ts format 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`logical-expression.ng format 1`] = `
exports[`logical-expression.ng - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["__ng_interpolation"]
printWidth: 80
@@ -21,7 +21,7 @@ trailingComma: "none"
================================================================================
`;
exports[`pipe-expression.ng format 1`] = `
exports[`pipe-expression.ng - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["__ng_interpolation"]
printWidth: 80
@@ -1,7 +1,8 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`arrow_call.js format 1`] = `
exports[`arrow_call.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "flow", "typescript"]
printWidth: 80
| printWidth
@@ -110,7 +111,7 @@ promise.then((result) =>
================================================================================
`;
exports[`arrow_call.js format 2`] = `
exports[`arrow_call.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["babel", "flow", "typescript"]
printWidth: 80
@@ -221,9 +222,8 @@ promise.then((result) =>
================================================================================
`;
exports[`arrow_call.js format 3`] = `
exports[`arrow_call.js format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "flow", "typescript"]
printWidth: 80
| printWidth
+20 -20
View File
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`arrow_function_expression.js format 1`] = `
exports[`arrow_function_expression.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -84,7 +84,7 @@ a = (b) => {
================================================================================
`;
exports[`arrow_function_expression.js format 2`] = `
exports[`arrow_function_expression.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -168,7 +168,7 @@ a = b => {
================================================================================
`;
exports[`block_like.js format 1`] = `
exports[`block_like.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -183,7 +183,7 @@ a = () => ({} = this);
================================================================================
`;
exports[`block_like.js format 2`] = `
exports[`block_like.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -198,7 +198,7 @@ a = () => ({} = this);
================================================================================
`;
exports[`call.js format 1`] = `
exports[`call.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -995,7 +995,7 @@ foo(
================================================================================
`;
exports[`call.js format 2`] = `
exports[`call.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -1792,7 +1792,7 @@ foo(
================================================================================
`;
exports[`comment.js format 1`] = `
exports[`comment.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -1865,7 +1865,7 @@ export const bem = (block) =>
================================================================================
`;
exports[`comment.js format 2`] = `
exports[`comment.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -1938,7 +1938,7 @@ export const bem = block =>
================================================================================
`;
exports[`currying.js format 1`] = `
exports[`currying.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -1985,7 +1985,7 @@ const middleware = (options) => (req, res, next) => {
================================================================================
`;
exports[`currying.js format 2`] = `
exports[`currying.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -2032,7 +2032,7 @@ const middleware = options => (req, res, next) => {
================================================================================
`;
exports[`long-call-no-args.js format 1`] = `
exports[`long-call-no-args.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -2050,7 +2050,7 @@ veryLongCall(
================================================================================
`;
exports[`long-call-no-args.js format 2`] = `
exports[`long-call-no-args.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -2068,7 +2068,7 @@ veryLongCall(
================================================================================
`;
exports[`long-contents.js format 1`] = `
exports[`long-contents.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -2092,7 +2092,7 @@ const foo = () => {
================================================================================
`;
exports[`long-contents.js format 2`] = `
exports[`long-contents.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -2116,7 +2116,7 @@ const foo = () => {
================================================================================
`;
exports[`parens.js format 1`] = `
exports[`parens.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -2167,7 +2167,7 @@ foo((a) => b, d);
================================================================================
`;
exports[`parens.js format 2`] = `
exports[`parens.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -2218,7 +2218,7 @@ foo(a => b, d);
================================================================================
`;
exports[`short_body.js format 1`] = `
exports[`short_body.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -2243,7 +2243,7 @@ const initializeSnapshotState = (
================================================================================
`;
exports[`short_body.js format 2`] = `
exports[`short_body.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -2268,7 +2268,7 @@ const initializeSnapshotState = (
================================================================================
`;
exports[`type_params.js format 1`] = `
exports[`type_params.js - {"arrowParens":"always"} format 1`] = `
====================================options=====================================
arrowParens: "always"
parsers: ["babel", "typescript"]
@@ -2283,7 +2283,7 @@ printWidth: 80
================================================================================
`;
exports[`type_params.js format 2`] = `
exports[`type_params.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["babel", "typescript"]
@@ -1,5 +1,26 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`await.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
const doBothThings = async () => {
const request = doAsyncThing();
return (await request)::doSyncThing();
};
=====================================output=====================================
const doBothThings = async () => {
const request = doAsyncThing()
return (await request)::doSyncThing()
}
================================================================================
`;
exports[`await.js format 1`] = `
====================================options=====================================
parsers: ["babel"]
@@ -20,23 +41,83 @@ const doBothThings = async () => {
================================================================================
`;
exports[`await.js format 2`] = `
exports[`bind_parens.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
const doBothThings = async () => {
const request = doAsyncThing();
return (await request)::doSyncThing();
};
(a || b)::c;
a || (b::c);
::obj.prop;
(void 0)::func();
(+0)::is(-0);
a::(b.c);
a::(b.c());
a::b.c();
a::(b.c()());
a::((b.c())());
a::(b.c())();
a::(b.c().d);
a::(c().d.e);
a::(b());
a::(b::c());
a::(b()::c);
a::(b().c::d);
a::(b.c::d);
a::(b::c.d);
a::(b.c::d::e);
a::(b::c::d);
a::(b::c::d.e);
a::((b::c::d).e);
a::(void 0);
a::(b.c()::d.e);
a::(b.c::d.e);
a::(b.c::d.e)::f.g;
b.c::d.e;
(b.c::d).e;
(b::c::d).e;
new (a::b)();
new f(a::b);
f[a::b];
f[a::b()];
=====================================output=====================================
const doBothThings = async () => {
const request = doAsyncThing()
return (await request)::doSyncThing()
}
;(a || b)::c
a || b::c
;::obj.prop
;(void 0)::func()
;(+0)::is(-0)
a::b.c
a::(b.c())
a::b.c()
a::(b.c()())
a::(b.c()())
a::(b.c())()
a::(b.c().d)
a::(c().d.e)
a::(b())
a::(b::c())
a::(b()::c)
a::(b().c::d)
a::(b.c::d)
a::(b::c.d)
a::(b.c::d::e)
a::(b::c::d)
a::(b::c::d.e)
a::(b::c::d).e
a::(void 0)
a::(b.c()::d.e)
a::(b.c::d.e)
a::(b.c::d.e)::f.g
b.c::d.e
;(b.c::d).e
;(b::c::d).e
new (a::b)()
new f(a::b)
f[a::b]
f[a::b()]
================================================================================
`;
@@ -121,83 +202,33 @@ f[a::b()];
================================================================================
`;
exports[`bind_parens.js format 2`] = `
exports[`long_name_method.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
(a || b)::c;
a || (b::c);
::obj.prop;
(void 0)::func();
(+0)::is(-0);
a::(b.c);
a::(b.c());
a::b.c();
a::(b.c()());
a::((b.c())());
a::(b.c())();
a::(b.c().d);
a::(c().d.e);
a::(b());
a::(b::c());
a::(b()::c);
a::(b().c::d);
a::(b.c::d);
a::(b::c.d);
a::(b.c::d::e);
a::(b::c::d);
a::(b::c::d.e);
a::((b::c::d).e);
a::(void 0);
a::(b.c()::d.e);
a::(b.c::d.e);
a::(b.c::d.e)::f.g;
b.c::d.e;
(b.c::d).e;
(b::c::d).e;
new (a::b)();
new f(a::b);
f[a::b];
f[a::b()];
class X {
constructor() {
this.testLongNameMethodAndSomethingElseLallala = ::this.testLongNameMethodAndSomethingElseLallala;
}
testLongNameMethodAndSomethingElseLallala() {
return true;
}
}
=====================================output=====================================
;(a || b)::c
a || b::c
;::obj.prop
;(void 0)::func()
;(+0)::is(-0)
a::b.c
a::(b.c())
a::b.c()
a::(b.c()())
a::(b.c()())
a::(b.c())()
a::(b.c().d)
a::(c().d.e)
a::(b())
a::(b::c())
a::(b()::c)
a::(b().c::d)
a::(b.c::d)
a::(b::c.d)
a::(b.c::d::e)
a::(b::c::d)
a::(b::c::d.e)
a::(b::c::d).e
a::(void 0)
a::(b.c()::d.e)
a::(b.c::d.e)
a::(b.c::d.e)::f.g
b.c::d.e
;(b.c::d).e
;(b::c::d).e
new (a::b)()
new f(a::b)
f[a::b]
f[a::b()]
class X {
constructor() {
this.testLongNameMethodAndSomethingElseLallala =
::this.testLongNameMethodAndSomethingElseLallala
}
testLongNameMethodAndSomethingElseLallala() {
return true
}
}
================================================================================
`;
@@ -232,32 +263,48 @@ class X {
================================================================================
`;
exports[`long_name_method.js format 2`] = `
exports[`method_chain.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
class X {
constructor() {
this.testLongNameMethodAndSomethingElseLallala = ::this.testLongNameMethodAndSomethingElseLallala;
}
testLongNameMethodAndSomethingElseLallala() {
return true;
}
}
=====================================output=====================================
class X {
constructor() {
this.testLongNameMethodAndSomethingElseLallala =
::this.testLongNameMethodAndSomethingElseLallala
}
import {interval} from 'rxjs/observable/interval';
import {filter} from 'rxjs/operator/filter';
import {take} from 'rxjs/operator/take';
import {map} from 'rxjs/operator/map';
import {throttle} from 'rxjs/operator/throttle';
import {takeUntil} from 'rxjs/operator/takeUntil';
testLongNameMethodAndSomethingElseLallala() {
return true
}
function test(observable) {
return observable
::filter(data => data.someTest)
::throttle(() =>
interval(10)
::take(1)
::takeUntil(observable::filter(data => someOtherTest))
)
::map(someFunction);
}
=====================================output=====================================
import { interval } from "rxjs/observable/interval"
import { filter } from "rxjs/operator/filter"
import { take } from "rxjs/operator/take"
import { map } from "rxjs/operator/map"
import { throttle } from "rxjs/operator/throttle"
import { takeUntil } from "rxjs/operator/takeUntil"
function test(observable) {
return observable
::filter((data) => data.someTest)
::throttle(() =>
interval(10)
::take(1)
::takeUntil(observable::filter((data) => someOtherTest))
)
::map(someFunction)
}
================================================================================
@@ -309,48 +356,31 @@ function test(observable) {
================================================================================
`;
exports[`method_chain.js format 2`] = `
exports[`short_name_method.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
import {interval} from 'rxjs/observable/interval';
import {filter} from 'rxjs/operator/filter';
import {take} from 'rxjs/operator/take';
import {map} from 'rxjs/operator/map';
import {throttle} from 'rxjs/operator/throttle';
import {takeUntil} from 'rxjs/operator/takeUntil';
function test(observable) {
return observable
::filter(data => data.someTest)
::throttle(() =>
interval(10)
::take(1)
::takeUntil(observable::filter(data => someOtherTest))
)
::map(someFunction);
class X {
constructor() {
this.shortMethod = ::this.shortMethod;
}
shortMethod() {
return true;
}
}
=====================================output=====================================
import { interval } from "rxjs/observable/interval"
import { filter } from "rxjs/operator/filter"
import { take } from "rxjs/operator/take"
import { map } from "rxjs/operator/map"
import { throttle } from "rxjs/operator/throttle"
import { takeUntil } from "rxjs/operator/takeUntil"
class X {
constructor() {
this.shortMethod = ::this.shortMethod
}
function test(observable) {
return observable
::filter((data) => data.someTest)
::throttle(() =>
interval(10)
::take(1)
::takeUntil(observable::filter((data) => someOtherTest))
)
::map(someFunction)
shortMethod() {
return true
}
}
================================================================================
@@ -385,32 +415,43 @@ class X {
================================================================================
`;
exports[`short_name_method.js format 2`] = `
exports[`unary.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
class X {
constructor() {
this.shortMethod = ::this.shortMethod;
}
shortMethod() {
return true;
}
}
=====================================output=====================================
class X {
constructor() {
this.shortMethod = ::this.shortMethod
}
!x::y;
!(x::y /* foo */);
!(/* foo */ x::y);
!(
/* foo */
x::y
);
!(
x::y
/* foo */
);
!(
x::y // foo
);
shortMethod() {
return true
}
}
=====================================output=====================================
!x::y
!(x::y /* foo */)
!(/* foo */ x::y)
!(
/* foo */
x::y
)
!(
x::y
/* foo */
)
!(
x::y // foo
)
================================================================================
`;
@@ -454,44 +495,3 @@ printWidth: 80
================================================================================
`;
exports[`unary.js format 2`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
!x::y;
!(x::y /* foo */);
!(/* foo */ x::y);
!(
/* foo */
x::y
);
!(
x::y
/* foo */
);
!(
x::y // foo
);
=====================================output=====================================
!x::y
!(x::y /* foo */)
!(/* foo */ x::y)
!(
/* foo */
x::y
)
!(
x::y
/* foo */
)
!(
x::y // foo
)
================================================================================
`;
@@ -1,5 +1,22 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`array.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
const arr1 = [1,2,3,4];
const arr2 = [1, 2, 3, 4];
=====================================output=====================================
const arr1 = [1, 2, 3, 4];
const arr2 = [1, 2, 3, 4];
================================================================================
`;
exports[`array.js format 1`] = `
====================================options=====================================
parsers: ["flow", "typescript"]
@@ -16,19 +33,19 @@ const arr2 = [1, 2, 3, 4];
================================================================================
`;
exports[`array.js format 2`] = `
exports[`object.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
const arr1 = [1,2,3,4];
const arr2 = [1, 2, 3, 4];
const obj1 = {a:1, b:2, c:3}
const obj2 = { a:1, b:2, c:3 };
=====================================output=====================================
const arr1 = [1, 2, 3, 4];
const arr2 = [1, 2, 3, 4];
const obj1 = {a: 1, b: 2, c: 3};
const obj2 = {a: 1, b: 2, c: 3};
================================================================================
`;
@@ -48,20 +65,3 @@ const obj2 = { a: 1, b: 2, c: 3 };
================================================================================
`;
exports[`object.js format 2`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
const obj1 = {a:1, b:2, c:3}
const obj2 = { a:1, b:2, c:3 };
=====================================output=====================================
const obj1 = {a: 1, b: 2, c: 3};
const obj2 = {a: 1, b: 2, c: 3};
================================================================================
`;
@@ -1,5 +1,134 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`private_fields.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
class A { #x; #y; }
class B { #x = 0; #y = 1; }
class C {
static #x;
static #y = 1;
}
class D {
#x
#y
}
class Point {
#x = 1;
#y = 2;
constructor(x = 0, y = 0) {
this.#x = +x;
this.#y = +y;
}
get x() { return this.#x }
set x(value) { this.#x = +value }
get y() { return this.#y }
set y(value) { this.#y = +value }
equals(p) { return this.#x === p.#x && this.#y === p.#y }
toString() { return \`Point<\${ this.#x },\${ this.#y }>\` }
}
class E {
async #a() {}
#b() {}
get #c() {}
set #c(bar) {}
*#d() {}
async *#e() {}
get #f() {}
set #f(taz) {}
}
class F {
#func(id, { blog: { title } }) {
return id + title;
}
}
=====================================output=====================================
class A {
#x
#y
}
class B {
#x = 0
#y = 1
}
class C {
static #x
static #y = 1
}
class D {
#x
#y
}
class Point {
#x = 1
#y = 2
constructor(x = 0, y = 0) {
this.#x = +x
this.#y = +y
}
get x() {
return this.#x
}
set x(value) {
this.#x = +value
}
get y() {
return this.#y
}
set y(value) {
this.#y = +value
}
equals(p) {
return this.#x === p.#x && this.#y === p.#y
}
toString() {
return \`Point<\${this.#x},\${this.#y}>\`
}
}
class E {
async #a() {}
#b() {}
get #c() {}
set #c(bar) {}
*#d() {}
async *#e() {}
get #f() {}
set #f(taz) {}
}
class F {
#func(id, { blog: { title } }) {
return id + title
}
}
================================================================================
`;
exports[`private_fields.js format 1`] = `
====================================options=====================================
parsers: ["babel"]
@@ -128,130 +257,28 @@ class F {
================================================================================
`;
exports[`private_fields.js format 2`] = `
exports[`with_comments.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
class A { #x; #y; }
class B { #x = 0; #y = 1; }
class C {
static #x;
static #y = 1;
}
class D {
#x
#y
}
class Point {
#x = 1;
#y = 2;
constructor(x = 0, y = 0) {
this.#x = +x;
this.#y = +y;
}
get x() { return this.#x }
set x(value) { this.#x = +value }
get y() { return this.#y }
set y(value) { this.#y = +value }
equals(p) { return this.#x === p.#x && this.#y === p.#y }
toString() { return \`Point<\${ this.#x },\${ this.#y }>\` }
}
class E {
async #a() {}
#b() {}
get #c() {}
set #c(bar) {}
*#d() {}
async *#e() {}
get #f() {}
set #f(taz) {}
}
class F {
#func(id, { blog: { title } }) {
return id + title;
}
class A {
#foobar =
// comment to break
1 +
// comment to break again
2;
}
=====================================output=====================================
class A {
#x
#y
}
class B {
#x = 0
#y = 1
}
class C {
static #x
static #y = 1
}
class D {
#x
#y
}
class Point {
#x = 1
#y = 2
constructor(x = 0, y = 0) {
this.#x = +x
this.#y = +y
}
get x() {
return this.#x
}
set x(value) {
this.#x = +value
}
get y() {
return this.#y
}
set y(value) {
this.#y = +value
}
equals(p) {
return this.#x === p.#x && this.#y === p.#y
}
toString() {
return \`Point<\${this.#x},\${this.#y}>\`
}
}
class E {
async #a() {}
#b() {}
get #c() {}
set #c(bar) {}
*#d() {}
async *#e() {}
get #f() {}
set #f(taz) {}
}
class F {
#func(id, { blog: { title } }) {
return id + title
}
#foobar =
// comment to break
1 +
// comment to break again
2
}
================================================================================
@@ -282,30 +309,3 @@ class A {
================================================================================
`;
exports[`with_comments.js format 2`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
class A {
#foobar =
// comment to break
1 +
// comment to break again
2;
}
=====================================output=====================================
class A {
#foobar =
// comment to break
1 +
// comment to break again
2
}
================================================================================
`;
File diff suppressed because it is too large. Load diff
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`jsx_same_line.js format 1`] = `
exports[`jsx_same_line.js - {"jsxBracketSameLine":true} format 1`] = `
====================================options=====================================
jsxBracketSameLine: true
parsers: ["flow", "babel", "typescript"]
@@ -1,5 +1,37 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`custom-selector.css - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
@custom-selector :--icon i[ class ^= 'icon-' ], i[ class *= ' icon-' ];
@custom-selector
:--icon
i[
class
^=
'icon-'
]
,
i[
class
*=
' icon-'
]
;
=====================================output=====================================
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
================================================================================
`;
exports[`custom-selector.css format 1`] = `
====================================options=====================================
parsers: ["css"]
@@ -31,34 +63,24 @@ class
================================================================================
`;
exports[`custom-selector.css format 2`] = `
exports[`insensitive.css - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
@custom-selector :--icon i[ class ^= 'icon-' ], i[ class *= ' icon-' ];
@custom-selector
:--icon
i[
class
^=
'icon-'
]
,
i[
class
*=
' icon-'
]
;
input[type="radio" i] {}
img[alt~="person" i][src*="lorem" i] {}
section:has(:not([type="radio" i], [type="checkbox" i])) {}
=====================================output=====================================
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
@custom-selector :--icon i[class^='icon-'], i[class*=' icon-'];
input[type='radio' i] {
}
img[alt~='person' i][src*='lorem' i] {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
================================================================================
`;
@@ -84,23 +106,28 @@ section:has(:not([type="radio" i], [type="checkbox" i])) {
================================================================================
`;
exports[`insensitive.css format 2`] = `
exports[`namespaces.css - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
input[type="radio" i] {}
img[alt~="person" i][src*="lorem" i] {}
section:has(:not([type="radio" i], [type="checkbox" i])) {}
@namespace foo "http://www.example.com";
[foo|att=val] {}
[*|att] {}
[|att] {}
[att] {}
=====================================output=====================================
input[type='radio' i] {
@namespace foo 'http://www.example.com';
[foo|att='val'] {
}
img[alt~='person' i][src*='lorem' i] {
[*|att] {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
[|att] {
}
[att] {
}
================================================================================
@@ -132,28 +159,38 @@ printWidth: 80
================================================================================
`;
exports[`namespaces.css format 2`] = `
exports[`quotes.css - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
@namespace foo "http://www.example.com";
[foo|att=val] {}
[*|att] {}
[|att] {}
[att] {}
a[id=test] {}
a[id="test"] {}
a[id='test'] {}
a[id=func("foo")] {}
a[class="(╯°□°)╯︵ ┻━┻"]{}
input:not([type="radio"]):not([type="checkbox"]) {}
input:not([type="radio"], [type="checkbox"]) {}
section:has(:not([type="radio"], [type="checkbox"])) {}
=====================================output=====================================
@namespace foo 'http://www.example.com';
[foo|att='val'] {
a[id='test'] {
}
[*|att] {
a[id='test'] {
}
[|att] {
a[id='test'] {
}
[att] {
a[id=func('foo')] {
}
a[class='(╯°□°)╯︵ ┻━┻'] {
}
input:not([type='radio']):not([type='checkbox']) {
}
input:not([type='radio'], [type='checkbox']) {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
================================================================================
@@ -195,39 +232,244 @@ section:has(:not([type="radio"], [type="checkbox"])) {
================================================================================
`;
exports[`quotes.css format 2`] = `
exports[`spaces.css - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
a[id=test] {}
a[id="test"] {}
a[id='test'] {}
a[id=func("foo")] {}
a[class="(╯°□°)╯︵ ┻━┻"]{}
input:not([type="radio"]):not([type="checkbox"]) {}
input:not([type="radio"], [type="checkbox"]) {}
section:has(:not([type="radio"], [type="checkbox"])) {}
[lang] {}
[ lang] {}
[lang ] {}
[ lang ] {}
[ lang ] {}
[
lang
] {}
span[lang] {}
span[ lang] {}
span[lang ] {}
span[ lang ] {}
span[ lang ] {}
span[lang='pt'] {}
span[lang ='pt'] {}
span[lang= 'pt'] {}
span[lang = 'pt'] {}
span[lang = 'pt'] {}
span[lang='pt' ] {}
span[lang='pt' ] {}
span[
lang
=
'pt'
] {}
span[ lang ~= 'en-us' ] {}
span[ lang ~= 'en-us' ] {}
span[ lang |='zh' ] {}
span[
lang
~=
'en-us'
] {}
a[ href ^= '#' ] {}
a[ href $= '.cn' ] {}
a[ href *= 'example' ] {}
a[
href
*=
'example'
] {}
input[ type = 'radio' i ] {}
input[ type = 'radio' i ] {}
input[ type ~= 'radio' i ] {}
input[ type ~= 'radio' i ] {}
input[
type
~=
'radio'
i
] {}
img[ alt = 'person' ][ src = 'lorem' ] {}
img[ alt = 'person' ][ src = 'lorem' ] {}
img[ alt ~= 'person' ][ src *= 'lorem' ] {}
img[ alt ~= 'person' ][ src *= 'lorem' ] {}
img[
alt
~=
'person'
][
src
*=
'lorem'
] {}
section:has(:not([type='radio'], [type='checkbox'])) {}
section:has(:not([type='radio' i], [type='checkbox' i])) {}
section:has(:not([ type = 'radio' ], [ type = 'checkbox' ])) {}
section:has(:not([ type = 'radio' i ], [ type = 'checkbox' i ])) {}
section:has(:not([ type = 'radio' ], [ type = 'checkbox' ])) {}
section:has(:not([ type = 'radio' i ], [ type = 'checkbox' i ])) {}
section:has(:not([
type
=
'radio'
], [
type
=
'checkbox'
])) {}
section:has(:not([
type
=
'radio'
i
], [
type
=
'checkbox'
i
])) {}
[foo|att=val] {}
[ foo | att = val ] {}
[ foo | att = val ] {}
[
foo
|
att
=
val
] {}
[*|att] {}
[ * | att ] {}
[ * | att ] {}
[
*
|
att
] {}
[|att] {}
[ | att ] {}
[ | att ] {}
[
|
att
] {}
=====================================output=====================================
a[id='test'] {
[lang] {
}
a[id='test'] {
[lang] {
}
a[id='test'] {
[lang] {
}
a[id=func('foo')] {
[lang] {
}
a[class='(╯°□°)╯︵ ┻━┻'] {
[lang] {
}
input:not([type='radio']):not([type='checkbox']) {
[lang] {
}
input:not([type='radio'], [type='checkbox']) {
span[lang] {
}
span[lang] {
}
span[lang] {
}
span[lang] {
}
span[lang] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang~='en-us'] {
}
span[lang~='en-us'] {
}
span[lang|='zh'] {
}
span[lang~='en-us'] {
}
a[href^='#'] {
}
a[href$='.cn'] {
}
a[href*='example'] {
}
a[href*='example'] {
}
input[type='radio' i] {
}
input[type='radio' i] {
}
input[type~='radio' i] {
}
input[type~='radio' i] {
}
input[type~='radio' i] {
}
img[alt='person'][src='lorem'] {
}
img[alt='person'][src='lorem'] {
}
img[alt~='person'][src*='lorem'] {
}
img[alt~='person'][src*='lorem'] {
}
img[alt~='person'][src*='lorem'] {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
[foo|att='val'] {
}
[foo|att='val'] {
}
[foo|att='val'] {
}
[foo|att='val'] {
}
[*|att] {
}
[*|att] {
}
[*|att] {
}
[*|att] {
}
[|att] {
}
[|att] {
}
[|att] {
}
[|att] {
}
================================================================================
`;
@@ -472,245 +714,3 @@ section:has(:not([type="radio" i], [type="checkbox" i])) {
================================================================================
`;
exports[`spaces.css format 2`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
[lang] {}
[ lang] {}
[lang ] {}
[ lang ] {}
[ lang ] {}
[
lang
] {}
span[lang] {}
span[ lang] {}
span[lang ] {}
span[ lang ] {}
span[ lang ] {}
span[lang='pt'] {}
span[lang ='pt'] {}
span[lang= 'pt'] {}
span[lang = 'pt'] {}
span[lang = 'pt'] {}
span[lang='pt' ] {}
span[lang='pt' ] {}
span[
lang
=
'pt'
] {}
span[ lang ~= 'en-us' ] {}
span[ lang ~= 'en-us' ] {}
span[ lang |='zh' ] {}
span[
lang
~=
'en-us'
] {}
a[ href ^= '#' ] {}
a[ href $= '.cn' ] {}
a[ href *= 'example' ] {}
a[
href
*=
'example'
] {}
input[ type = 'radio' i ] {}
input[ type = 'radio' i ] {}
input[ type ~= 'radio' i ] {}
input[ type ~= 'radio' i ] {}
input[
type
~=
'radio'
i
] {}
img[ alt = 'person' ][ src = 'lorem' ] {}
img[ alt = 'person' ][ src = 'lorem' ] {}
img[ alt ~= 'person' ][ src *= 'lorem' ] {}
img[ alt ~= 'person' ][ src *= 'lorem' ] {}
img[
alt
~=
'person'
][
src
*=
'lorem'
] {}
section:has(:not([type='radio'], [type='checkbox'])) {}
section:has(:not([type='radio' i], [type='checkbox' i])) {}
section:has(:not([ type = 'radio' ], [ type = 'checkbox' ])) {}
section:has(:not([ type = 'radio' i ], [ type = 'checkbox' i ])) {}
section:has(:not([ type = 'radio' ], [ type = 'checkbox' ])) {}
section:has(:not([ type = 'radio' i ], [ type = 'checkbox' i ])) {}
section:has(:not([
type
=
'radio'
], [
type
=
'checkbox'
])) {}
section:has(:not([
type
=
'radio'
i
], [
type
=
'checkbox'
i
])) {}
[foo|att=val] {}
[ foo | att = val ] {}
[ foo | att = val ] {}
[
foo
|
att
=
val
] {}
[*|att] {}
[ * | att ] {}
[ * | att ] {}
[
*
|
att
] {}
[|att] {}
[ | att ] {}
[ | att ] {}
[
|
att
] {}
=====================================output=====================================
[lang] {
}
[lang] {
}
[lang] {
}
[lang] {
}
[lang] {
}
[lang] {
}
span[lang] {
}
span[lang] {
}
span[lang] {
}
span[lang] {
}
span[lang] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang='pt'] {
}
span[lang~='en-us'] {
}
span[lang~='en-us'] {
}
span[lang|='zh'] {
}
span[lang~='en-us'] {
}
a[href^='#'] {
}
a[href$='.cn'] {
}
a[href*='example'] {
}
a[href*='example'] {
}
input[type='radio' i] {
}
input[type='radio' i] {
}
input[type~='radio' i] {
}
input[type~='radio' i] {
}
input[type~='radio' i] {
}
img[alt='person'][src='lorem'] {
}
img[alt='person'][src='lorem'] {
}
img[alt~='person'][src*='lorem'] {
}
img[alt~='person'][src*='lorem'] {
}
img[alt~='person'][src*='lorem'] {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
section:has(:not([type='radio'], [type='checkbox'])) {
}
section:has(:not([type='radio' i], [type='checkbox' i])) {
}
[foo|att='val'] {
}
[foo|att='val'] {
}
[foo|att='val'] {
}
[foo|att='val'] {
}
[*|att] {
}
[*|att] {
}
[*|att] {
}
[*|att] {
}
[|att] {
}
[|att] {
}
[|att] {
}
[|att] {
}
================================================================================
`;
+197 -197
View File
@@ -1,5 +1,202 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`quotes.css - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
@charset "UTF-8";
/* @charset must always have double quotes: https://www.w3.org/TR/css-syntax-3/#determine-the-fallback-encoding */
/* Also, it has to be the very first thing in the file, but here are some more tests anyway: */
@charset 'UTF-8'; /* Single quotes are invalid here. Keep them since we don't know what the user is doing. */
@supports (content: one "two" three 'four') {
a[href="foo" y],
abbr[title^='It\\'s a trap!'],
img[src=""] {
/* Simple strings. */
content: "abc";
content: 'abc';
/* Escape. */
content: '\\A';
/* Emoji. */
content: '🐶';
/* Empty string. */
content: "";
content: '';
/* Single double quote. */
content: "\\"";
content: '"';
/* Single single quote. */
content: "'";
content: '\\'';
/* One of each. */
content: "\\"'";
content: '"\\'';
/* One of each with unnecessary escapes. */
content: "\\"\\'";
content: '\\"\\'';
/* More double quotes than single quotes. */
content: "\\"'\\"";
content: '"\\'"';
/* More single quotes than double quotes. */
content: "\\"''";
content: '"\\'\\'';
/* Two of each. */
content: "\\"\\"''";
content: '""\\'\\'';
/* Single backslash. */
content: '\\\\';
content: "\\\\";
/* Backslases. */
content: "\\"\\\\\\"\\\\\\\\\\" '\\'\\\\'\\\\\\'\\\\\\\\'";
content: '\\'\\\\\\'\\\\\\\\\\' "\\"\\\\"\\\\\\"\\\\\\\\"';
/* Somewhat more real-word example. */
content: "He's sayin': \\"How's it goin'?\\" Don't ask me why.";
content: 'He\\'s sayin\\': "How\\'s it goin\\'?" Don\\'t ask me why.';
/* Somewhat more real-word example 2. */
content: "var backslash = \\"\\\\\\", doubleQuote = '\\"';";
content: 'var backslash = "\\\\", doubleQuote = \\'"\\';';
/* Leave all "escapes" alone. */
content: "\\Abc4 foo \\n" /* "comment" */ "\\end";
content: '\\Abc4 foo \\n' /* 'comment' */ '\\end';
}
}
@import "file.css";
@import 'file.css';
@import url("foo.css");
@import url('foo.css');
@import "foo.css" screen and (orientation: landscape);
@import 'foo.css' screen and (orientation: landscape);
@foo "one";
@foo 'one';
@foo "one" two 'three';
@foo ("one");
@foo ('one');
@foo ("one" two 'three');
one "two" three {}
one 'two' three {}
=====================================output=====================================
@charset "UTF-8";
/* @charset must always have double quotes: https://www.w3.org/TR/css-syntax-3/#determine-the-fallback-encoding */
/* Also, it has to be the very first thing in the file, but here are some more tests anyway: */
@charset 'UTF-8'; /* Single quotes are invalid here. Keep them since we don't know what the user is doing. */
@supports (content: one 'two' three 'four') {
a[href='foo' y],
abbr[title^="It's a trap!"],
img[src=''] {
/* Simple strings. */
content: 'abc';
content: 'abc';
/* Escape. */
content: '\\A';
/* Emoji. */
content: '🐶';
/* Empty string. */
content: '';
content: '';
/* Single double quote. */
content: '"';
content: '"';
/* Single single quote. */
content: "'";
content: "'";
/* One of each. */
content: '"\\'';
content: '"\\'';
/* One of each with unnecessary escapes. */
content: '"\\'';
content: '"\\'';
/* More double quotes than single quotes. */
content: '"\\'"';
content: '"\\'"';
/* More single quotes than double quotes. */
content: "\\"''";
content: "\\"''";
/* Two of each. */
content: '""\\'\\'';
content: '""\\'\\'';
/* Single backslash. */
content: '\\\\';
content: '\\\\';
/* Backslases. */
content: "\\"\\\\\\"\\\\\\\\\\" ''\\\\'\\\\'\\\\\\\\'";
content: '\\'\\\\\\'\\\\\\\\\\' ""\\\\"\\\\"\\\\\\\\"';
/* Somewhat more real-word example. */
content: "He's sayin': \\"How's it goin'?\\" Don't ask me why.";
content: "He's sayin': \\"How's it goin'?\\" Don't ask me why.";
/* Somewhat more real-word example 2. */
content: 'var backslash = "\\\\", doubleQuote = \\'"\\';';
content: 'var backslash = "\\\\", doubleQuote = \\'"\\';';
/* Leave all "escapes" alone. */
content: '\\Abc4 foo \\n' /* "comment" */ '\\end';
content: '\\Abc4 foo \\n' /* 'comment' */ '\\end';
}
}
@import 'file.css';
@import 'file.css';
@import url('foo.css');
@import url('foo.css');
@import 'foo.css' screen and (orientation: landscape);
@import 'foo.css' screen and (orientation: landscape);
@foo "one";
@foo 'one';
@foo "one" two 'three';
@foo ("one");
@foo ('one');
@foo ("one" two 'three');
one 'two' three {
}
one 'two' three {
}
================================================================================
`;
exports[`quotes.css format 1`] = `
====================================options=====================================
parsers: ["css"]
@@ -195,200 +392,3 @@ one "two" three {
================================================================================
`;
exports[`quotes.css format 2`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
@charset "UTF-8";
/* @charset must always have double quotes: https://www.w3.org/TR/css-syntax-3/#determine-the-fallback-encoding */
/* Also, it has to be the very first thing in the file, but here are some more tests anyway: */
@charset 'UTF-8'; /* Single quotes are invalid here. Keep them since we don't know what the user is doing. */
@supports (content: one "two" three 'four') {
a[href="foo" y],
abbr[title^='It\\'s a trap!'],
img[src=""] {
/* Simple strings. */
content: "abc";
content: 'abc';
/* Escape. */
content: '\\A';
/* Emoji. */
content: '🐶';
/* Empty string. */
content: "";
content: '';
/* Single double quote. */
content: "\\"";
content: '"';
/* Single single quote. */
content: "'";
content: '\\'';
/* One of each. */
content: "\\"'";
content: '"\\'';
/* One of each with unnecessary escapes. */
content: "\\"\\'";
content: '\\"\\'';
/* More double quotes than single quotes. */
content: "\\"'\\"";
content: '"\\'"';
/* More single quotes than double quotes. */
content: "\\"''";
content: '"\\'\\'';
/* Two of each. */
content: "\\"\\"''";
content: '""\\'\\'';
/* Single backslash. */
content: '\\\\';
content: "\\\\";
/* Backslases. */
content: "\\"\\\\\\"\\\\\\\\\\" '\\'\\\\'\\\\\\'\\\\\\\\'";
content: '\\'\\\\\\'\\\\\\\\\\' "\\"\\\\"\\\\\\"\\\\\\\\"';
/* Somewhat more real-word example. */
content: "He's sayin': \\"How's it goin'?\\" Don't ask me why.";
content: 'He\\'s sayin\\': "How\\'s it goin\\'?" Don\\'t ask me why.';
/* Somewhat more real-word example 2. */
content: "var backslash = \\"\\\\\\", doubleQuote = '\\"';";
content: 'var backslash = "\\\\", doubleQuote = \\'"\\';';
/* Leave all "escapes" alone. */
content: "\\Abc4 foo \\n" /* "comment" */ "\\end";
content: '\\Abc4 foo \\n' /* 'comment' */ '\\end';
}
}
@import "file.css";
@import 'file.css';
@import url("foo.css");
@import url('foo.css');
@import "foo.css" screen and (orientation: landscape);
@import 'foo.css' screen and (orientation: landscape);
@foo "one";
@foo 'one';
@foo "one" two 'three';
@foo ("one");
@foo ('one');
@foo ("one" two 'three');
one "two" three {}
one 'two' three {}
=====================================output=====================================
@charset "UTF-8";
/* @charset must always have double quotes: https://www.w3.org/TR/css-syntax-3/#determine-the-fallback-encoding */
/* Also, it has to be the very first thing in the file, but here are some more tests anyway: */
@charset 'UTF-8'; /* Single quotes are invalid here. Keep them since we don't know what the user is doing. */
@supports (content: one 'two' three 'four') {
a[href='foo' y],
abbr[title^="It's a trap!"],
img[src=''] {
/* Simple strings. */
content: 'abc';
content: 'abc';
/* Escape. */
content: '\\A';
/* Emoji. */
content: '🐶';
/* Empty string. */
content: '';
content: '';
/* Single double quote. */
content: '"';
content: '"';
/* Single single quote. */
content: "'";
content: "'";
/* One of each. */
content: '"\\'';
content: '"\\'';
/* One of each with unnecessary escapes. */
content: '"\\'';
content: '"\\'';
/* More double quotes than single quotes. */
content: '"\\'"';
content: '"\\'"';
/* More single quotes than double quotes. */
content: "\\"''";
content: "\\"''";
/* Two of each. */
content: '""\\'\\'';
content: '""\\'\\'';
/* Single backslash. */
content: '\\\\';
content: '\\\\';
/* Backslases. */
content: "\\"\\\\\\"\\\\\\\\\\" ''\\\\'\\\\'\\\\\\\\'";
content: '\\'\\\\\\'\\\\\\\\\\' ""\\\\"\\\\"\\\\\\\\"';
/* Somewhat more real-word example. */
content: "He's sayin': \\"How's it goin'?\\" Don't ask me why.";
content: "He's sayin': \\"How's it goin'?\\" Don't ask me why.";
/* Somewhat more real-word example 2. */
content: 'var backslash = "\\\\", doubleQuote = \\'"\\';';
content: 'var backslash = "\\\\", doubleQuote = \\'"\\';';
/* Leave all "escapes" alone. */
content: '\\Abc4 foo \\n' /* "comment" */ '\\end';
content: '\\Abc4 foo \\n' /* 'comment' */ '\\end';
}
}
@import 'file.css';
@import 'file.css';
@import url('foo.css');
@import url('foo.css');
@import 'foo.css' screen and (orientation: landscape);
@import 'foo.css' screen and (orientation: landscape);
@foo "one";
@foo 'one';
@foo "one" two 'three';
@foo ("one");
@foo ('one');
@foo ("one" two 'three');
one 'two' three {
}
one 'two' three {
}
================================================================================
`;
+21 -21
View File
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`comments.scss format 1`] = `
exports[`comments.scss - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -37,7 +37,7 @@ trailingComma: "none"
================================================================================
`;
exports[`comments.scss format 2`] = `
exports[`comments.scss format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -73,11 +73,25 @@ printWidth: 80
================================================================================
`;
exports[`import_comma.scss - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
@import "rounded-corners", "text-shadow";
=====================================output=====================================
@import "rounded-corners", "text-shadow";
================================================================================
`;
exports[`import_comma.scss format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
@import "rounded-corners", "text-shadow";
@@ -88,21 +102,7 @@ trailingComma: "none"
================================================================================
`;
exports[`import_comma.scss format 2`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
| printWidth
=====================================input======================================
@import "rounded-corners", "text-shadow";
=====================================output=====================================
@import "rounded-corners", "text-shadow";
================================================================================
`;
exports[`scss.scss format 1`] = `
exports[`scss.scss - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -2131,7 +2131,7 @@ label {
================================================================================
`;
exports[`scss.scss format 2`] = `
exports[`scss.scss format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -4159,7 +4159,7 @@ label {
================================================================================
`;
exports[`string-concatanation.scss format 1`] = `
exports[`string-concatanation.scss - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -4184,7 +4184,7 @@ a {
================================================================================
`;
exports[`string-concatanation.scss format 2`] = `
exports[`string-concatanation.scss format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`at-rules.css format 1`] = `
exports[`at-rules.css - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
@@ -76,7 +76,7 @@ a {
================================================================================
`;
exports[`at-rules.css format 2`] = `
exports[`at-rules.css format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -151,7 +151,7 @@ a {
================================================================================
`;
exports[`declaration.css format 1`] = `
exports[`declaration.css - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
@@ -170,7 +170,7 @@ a {
================================================================================
`;
exports[`declaration.css format 2`] = `
exports[`declaration.css format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -188,7 +188,7 @@ a {
================================================================================
`;
exports[`list.css format 1`] = `
exports[`list.css - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
@@ -294,7 +294,7 @@ $breakpoint-map: (
================================================================================
`;
exports[`list.css format 2`] = `
exports[`list.css format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -399,7 +399,7 @@ $breakpoint-map: (
================================================================================
`;
exports[`map.css format 1`] = `
exports[`map.css - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
@@ -444,7 +444,7 @@ $map: (
================================================================================
`;
exports[`map.css format 2`] = `
exports[`map.css format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -488,7 +488,7 @@ $map: (
================================================================================
`;
exports[`selector_list.css format 1`] = `
exports[`selector_list.css - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
@@ -520,7 +520,7 @@ asdasldaskdhjkashdahsdkjahskdjhakjsdkjahsdhkasdhkajsdhakjsdhkajsdhjkahskjdkjahsj
================================================================================
`;
exports[`selector_list.css format 2`] = `
exports[`selector_list.css format 1`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
@@ -551,26 +551,26 @@ asdasldaskdhjkashdahsdkjahskdjhakjsdkjahsdhkasdhkajsdhakjsdhkajsdhjkahskjdkjahsj
================================================================================
`;
exports[`variable.css - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
$test: 1,;
$margin: 0, 2em, 0, 1.5em,;
=====================================output=====================================
$test: 1;
$margin: 0, 2em, 0, 1.5em;
================================================================================
`;
exports[`variable.css format 1`] = `
====================================options=====================================
parsers: ["css"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
$test: 1,;
$margin: 0, 2em, 0, 1.5em,;
=====================================output=====================================
$test: 1;
$margin: 0, 2em, 0, 1.5em;
================================================================================
`;
exports[`variable.css format 2`] = `
====================================options=====================================
parsers: ["scss"]
printWidth: 80
| printWidth
@@ -1,5 +1,32 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`test.html - {"embeddedLanguageFormatting":"off"} format 1`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["html"]
printWidth: 80
| printWidth
=====================================input======================================
<!doctype html>
<head>
<style>a {}</style>
<script>1 + 2</script>
</head>
=====================================output=====================================
<!DOCTYPE html>
<head>
<style>
a {}
</style>
<script>
1 + 2
</script>
</head>
================================================================================
`;
exports[`test.html format 1`] = `
====================================options=====================================
parsers: ["html"]
@@ -26,30 +53,3 @@ printWidth: 80
================================================================================
`;
exports[`test.html format 2`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["html"]
printWidth: 80
| printWidth
=====================================input======================================
<!doctype html>
<head>
<style>a {}</style>
<script>1 + 2</script>
</head>
=====================================output=====================================
<!DOCTYPE html>
<head>
<style>
a {}
</style>
<script>
1 + 2
</script>
</head>
================================================================================
`;
@@ -1,5 +1,44 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`test.js - {"embeddedLanguageFormatting":"off"} format 1`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["babel"]
printWidth: 80
| printWidth
=====================================input======================================
css\`a { }\`
md\`\`
graphql(\`{id}\`)
html\`<a>\`
@Component({
template: \`<a>\`,
styles: [\`a { }\`]
})
class TestComponent {}
=====================================output=====================================
css\`a { }\`;
md\`\`;
graphql(\`{id}\`);
html\`<a>\`;
@Component({
template: \`<a>\`,
styles: [\`a { }\`],
})
class TestComponent {}
================================================================================
`;
exports[`test.js format 1`] = `
====================================options=====================================
parsers: ["babel"]
@@ -53,42 +92,3 @@ class TestComponent {}
================================================================================
`;
exports[`test.js format 2`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["babel"]
printWidth: 80
| printWidth
=====================================input======================================
css\`a { }\`
md\`\`
graphql(\`{id}\`)
html\`<a>\`
@Component({
template: \`<a>\`,
styles: [\`a { }\`]
})
class TestComponent {}
=====================================output=====================================
css\`a { }\`;
md\`\`;
graphql(\`{id}\`);
html\`<a>\`;
@Component({
template: \`<a>\`,
styles: [\`a { }\`],
})
class TestComponent {}
================================================================================
`;
@@ -1,5 +1,24 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`test.md - {"embeddedLanguageFormatting":"off"} format 1`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["markdown"]
printWidth: 80
| printWidth
=====================================input======================================
\`\`\`js
1 + 2
\`\`\`
=====================================output=====================================
\`\`\`js
1 + 2
\`\`\`
================================================================================
`;
exports[`test.md format 1`] = `
====================================options=====================================
parsers: ["markdown"]
@@ -17,22 +36,3 @@ printWidth: 80
================================================================================
`;
exports[`test.md format 2`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["markdown"]
printWidth: 80
| printWidth
=====================================input======================================
\`\`\`js
1 + 2
\`\`\`
=====================================output=====================================
\`\`\`js
1 + 2
\`\`\`
================================================================================
`;
@@ -1,5 +1,32 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`in.vue - {"embeddedLanguageFormatting":"off"} format 1`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["vue"]
printWidth: 80
| printWidth
=====================================input======================================
<template>
<div>{{foo}}</div>
</template>
<script lang="ts">
1 + 2
</script>
=====================================output=====================================
<template>
<div>{{foo}}</div>
</template>
<script lang="ts">
1 + 2
</script>
================================================================================
`;
exports[`in.vue format 1`] = `
====================================options=====================================
parsers: ["vue"]
@@ -25,30 +52,3 @@ printWidth: 80
================================================================================
`;
exports[`in.vue format 2`] = `
====================================options=====================================
embeddedLanguageFormatting: "off"
parsers: ["vue"]
printWidth: 80
| printWidth
=====================================input======================================
<template>
<div>{{foo}}</div>
</template>
<script lang="ts">
1 + 2
</script>
=====================================output=====================================
<template>
<div>{{foo}}</div>
</template>
<script lang="ts">
1 + 2
</script>
================================================================================
`;
@@ -1,25 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`example.js format 1`] = `
====================================options=====================================
endOfLine: "lf"
parsers: ["babel"]
printWidth: 80
| printWidth
=====================================input======================================
function f() {<LF>
console.log("testing line endings");<LF>
}<LF>
=====================================output=====================================
function f() {<LF>
console.log("testing line endings");<LF>
}<LF>
================================================================================
`;
exports[`example.js format 2`] = `
exports[`example.js - {"endOfLine":"cr"} format 1`] = `
====================================options=====================================
endOfLine: "cr"
parsers: ["babel"]
@@ -38,7 +19,7 @@ function f() {<CR>
================================================================================
`;
exports[`example.js format 3`] = `
exports[`example.js - {"endOfLine":"crlf"} format 1`] = `
====================================options=====================================
endOfLine: "crlf"
parsers: ["babel"]
@@ -57,66 +38,26 @@ function f() {<CRLF>
================================================================================
`;
exports[`multiline.js format 1`] = `
exports[`example.js - {"endOfLine":"lf"} format 1`] = `
====================================options=====================================
endOfLine: "lf"
parsers: ["babel"]
printWidth: 80
| printWidth
=====================================input======================================
type IAmIncredibleLongParameterType = {};<LF>
const IAmAnotherFunctionName = (_0: IAmIncredibleLongParameterType) => {};<LF>
export const IAmIncredibleLongFunctionName = IAmAnotherFunctionName(<LF>
(_0: IAmIncredibleLongParameterType) => {<LF>
setTimeout(() => {<LF>
/*<LF>
Multiline comment<LF>
Multiline comment<LF>
Multiline comment<LF>
*/<LF>
console.log(<LF>
'Multiline string\\<LF>
Multiline string\\<LF>
Multiline string'<LF>
);<LF>
console.log(<LF>
\`Multiline \\n string\\<LF>
Multiline string\\<LF>
Multiline string\`<LF>
);<LF>
});<LF>
}<LF>
);<LF>
function f() {<LF>
console.log("testing line endings");<LF>
}<LF>
=====================================output=====================================
type IAmIncredibleLongParameterType = {};<LF>
const IAmAnotherFunctionName = (_0: IAmIncredibleLongParameterType) => {};<LF>
export const IAmIncredibleLongFunctionName = IAmAnotherFunctionName(<LF>
(_0: IAmIncredibleLongParameterType) => {<LF>
setTimeout(() => {<LF>
/*<LF>
Multiline comment<LF>
Multiline comment<LF>
Multiline comment<LF>
*/<LF>
console.log(<LF>
"Multiline string\\<LF>
Multiline string\\<LF>
Multiline string"<LF>
);<LF>
console.log(<LF>
\`Multiline \\n string\\<LF>
Multiline string\\<LF>
Multiline string\`<LF>
);<LF>
});<LF>
}<LF>
);<LF>
function f() {<LF>
console.log("testing line endings");<LF>
}<LF>
================================================================================
`;
exports[`multiline.js format 2`] = `
exports[`multiline.js - {"endOfLine":"cr"} format 1`] = `
====================================options=====================================
endOfLine: "cr"
parsers: ["babel"]
@@ -175,7 +116,7 @@ export const IAmIncredibleLongFunctionName = IAmAnotherFunctionName(<CR>
================================================================================
`;
exports[`multiline.js format 3`] = `
exports[`multiline.js - {"endOfLine":"crlf"} format 1`] = `
====================================options=====================================
endOfLine: "crlf"
parsers: ["babel"]
@@ -233,3 +174,62 @@ export const IAmIncredibleLongFunctionName = IAmAnotherFunctionName(<CRLF>
================================================================================
`;
exports[`multiline.js - {"endOfLine":"lf"} format 1`] = `
====================================options=====================================
endOfLine: "lf"
parsers: ["babel"]
printWidth: 80
| printWidth
=====================================input======================================
type IAmIncredibleLongParameterType = {};<LF>
const IAmAnotherFunctionName = (_0: IAmIncredibleLongParameterType) => {};<LF>
export const IAmIncredibleLongFunctionName = IAmAnotherFunctionName(<LF>
(_0: IAmIncredibleLongParameterType) => {<LF>
setTimeout(() => {<LF>
/*<LF>
Multiline comment<LF>
Multiline comment<LF>
Multiline comment<LF>
*/<LF>
console.log(<LF>
'Multiline string\\<LF>
Multiline string\\<LF>
Multiline string'<LF>
);<LF>
console.log(<LF>
\`Multiline \\n string\\<LF>
Multiline string\\<LF>
Multiline string\`<LF>
);<LF>
});<LF>
}<LF>
);<LF>
=====================================output=====================================
type IAmIncredibleLongParameterType = {};<LF>
const IAmAnotherFunctionName = (_0: IAmIncredibleLongParameterType) => {};<LF>
export const IAmIncredibleLongFunctionName = IAmAnotherFunctionName(<LF>
(_0: IAmIncredibleLongParameterType) => {<LF>
setTimeout(() => {<LF>
/*<LF>
Multiline comment<LF>
Multiline comment<LF>
Multiline comment<LF>
*/<LF>
console.log(<LF>
"Multiline string\\<LF>
Multiline string\\<LF>
Multiline string"<LF>
);<LF>
console.log(<LF>
\`Multiline \\n string\\<LF>
Multiline string\\<LF>
Multiline string\`<LF>
);<LF>
});<LF>
}<LF>
);<LF>
================================================================================
`;
@@ -1,5 +1,41 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`custom_block.vue - {"embeddedLanguageFormatting":"off"} error test 1`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
exports[`custom_block.vue - {"semi":false} error test 1`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
exports[`custom_block.vue - {"trailingComma":"none"} error test 1`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
exports[`custom_block.vue - {"vueIndentScriptAndStyle":true} error test 1`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
exports[`custom_block.vue error test 1`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
@@ -17,39 +53,3 @@ exports[`custom_block.vue error test 2`] = `
3 | </custom>
4 | "
`;
exports[`custom_block.vue error test 3`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
exports[`custom_block.vue error test 4`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
exports[`custom_block.vue error test 5`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
exports[`custom_block.vue error test 6`] = `
"Unexpected character \\"\\"\\" (2:16)
1 | <custom lang=\\"js\\">
> 2 | const foo = \\"</\\";
| ^
3 | </custom>
4 | "
`;
+40 -40
View File
@@ -1,5 +1,40 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`bracket.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
export {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns
};
export {fitsIn, oneLine};
=====================================output=====================================
export {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns,
};
export {fitsIn, oneLine};
================================================================================
`;
exports[`bracket.js format 1`] = `
====================================options=====================================
parsers: ["flow", "typescript"]
@@ -34,37 +69,19 @@ export { fitsIn, oneLine };
================================================================================
`;
exports[`bracket.js format 2`] = `
exports[`empty.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
export {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns
};
export {fitsIn, oneLine};
export {};
export {} from ".";
=====================================output=====================================
export {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns,
};
export {fitsIn, oneLine};
export {};
export {} from ".";
================================================================================
`;
@@ -84,20 +101,3 @@ export {} from ".";
================================================================================
`;
exports[`empty.js format 2`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
export {};
export {} from ".";
=====================================output=====================================
export {};
export {} from ".";
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`enum-boolean-explicit.js format 1`] = `
exports[`enum-boolean-explicit.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -25,7 +25,7 @@ enum E of boolean {
================================================================================
`;
exports[`enum-boolean-implicit.js format 1`] = `
exports[`enum-boolean-implicit.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -50,7 +50,7 @@ enum E {
================================================================================
`;
exports[`enum-comments.js format 1`] = `
exports[`enum-comments.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -116,7 +116,7 @@ enum /*Q*/ E6 of string {}
================================================================================
`;
exports[`enum-empty.js format 1`] = `
exports[`enum-empty.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -135,7 +135,7 @@ enum E {}
================================================================================
`;
exports[`enum-export.js format 1`] = `
exports[`enum-export.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -158,7 +158,7 @@ export default enum B {};
================================================================================
`;
exports[`enum-name.js format 1`] = `
exports[`enum-name.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -178,7 +178,7 @@ enum type {}
================================================================================
`;
exports[`enum-no-trailing-comma.js format 1`] = `
exports[`enum-no-trailing-comma.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -201,7 +201,7 @@ enum E {
================================================================================
`;
exports[`enum-number-explicit.js format 1`] = `
exports[`enum-number-explicit.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -226,7 +226,7 @@ enum E of number {
================================================================================
`;
exports[`enum-number-implicit.js format 1`] = `
exports[`enum-number-implicit.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -251,7 +251,7 @@ enum E {
================================================================================
`;
exports[`enum-string-explicit-defaulted.js format 1`] = `
exports[`enum-string-explicit-defaulted.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -276,7 +276,7 @@ enum E of string {
================================================================================
`;
exports[`enum-string-explicit-initialized.js format 1`] = `
exports[`enum-string-explicit-initialized.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -301,7 +301,7 @@ enum E of string {
================================================================================
`;
exports[`enum-string-implicit-defaulted.js format 1`] = `
exports[`enum-string-implicit-defaulted.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -326,7 +326,7 @@ enum E {
================================================================================
`;
exports[`enum-string-implicit-initialized.js format 1`] = `
exports[`enum-string-implicit-initialized.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -351,7 +351,7 @@ enum E {
================================================================================
`;
exports[`enum-symbol.js format 1`] = `
exports[`enum-symbol.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel-flow"]
printWidth: 80
@@ -1,5 +1,55 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`single.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["flow", "babel"]
printWidth: 80
| printWidth
=====================================input======================================
const selectorByPath:
Path
=> SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>
> = memoizeWithArgs(/* ... */)
=====================================output=====================================
const selectorByPath: Path => SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>
> = memoizeWithArgs(/* ... */);
================================================================================
`;
exports[`single.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
const selectorByPath:
Path
=> SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>
> = memoizeWithArgs(/* ... */)
=====================================output=====================================
const selectorByPath: (Path) => SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>,
> = memoizeWithArgs(/* ... */);
================================================================================
`;
exports[`single.js format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
@@ -24,52 +74,276 @@ const selectorByPath: (Path) => SomethingSelector<
================================================================================
`;
exports[`single.js format 2`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
const selectorByPath:
Path
=> SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>
> = memoizeWithArgs(/* ... */)
=====================================output=====================================
const selectorByPath: (Path) => SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>,
> = memoizeWithArgs(/* ... */);
================================================================================
`;
exports[`single.js format 3`] = `
exports[`test.js - {"arrowParens":"avoid"} format 1`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["flow", "babel"]
printWidth: 80
| printWidth
=====================================input======================================
const selectorByPath:
Path
=> SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>
> = memoizeWithArgs(/* ... */)
type Banana = {
eat: string => boolean,
};
type Hex = {n: 0x01};
type T1 = { method: (a) => void };
type T2 = { method(a): void };
declare class X { method(a): void }
declare function f(a): void;
var f: (a) => void;
interface F1 { m(string): number }
interface F2 { m: (string) => number }
function f1(o: { f: (string) => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = (/* comment */ arg) => void;
type f5 = (arg /* comment */) => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: child_process$ChildProcess => FlowIDEConnection =
defaultIDEConnectionFactory,
) {
}
}
interface F {
ideConnectionFactoryLongLongLong: (child_process$ChildProcess) => FlowIDEConnection
}
type ExtractType = <A>(B<C>) => D
type T3 = ?(() => A);
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = (?() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ?(?(() => A));
type T8 = ?(?() => A) | B;
=====================================output=====================================
const selectorByPath: Path => SomethingSelector<
SomethingUEditorContextType,
SomethingUEditorContextType,
SomethingBulkValue<string>
> = memoizeWithArgs(/* ... */);
type Banana = {
eat: string => boolean,
};
type Hex = { n: 0x01 };
type T1 = { method: a => void };
type T2 = { method(a): void };
declare class X {
method(a): void;
}
declare function f(a): void;
var f: a => void;
interface F1 {
m(string): number;
}
interface F2 {
m: string => number;
}
function f1(o: { f: string => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = /* comment */ arg => void;
type f5 = arg /* comment */ => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: child_process$ChildProcess => FlowIDEConnection = defaultIDEConnectionFactory
) {}
}
interface F {
ideConnectionFactoryLongLongLong: child_process$ChildProcess => FlowIDEConnection;
}
type ExtractType = <A>(B<C>) => D;
type T3 = ?() => A;
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = ?(() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ??(() => A);
type T8 = ??(() => A) | B;
================================================================================
`;
exports[`test.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
type Banana = {
eat: string => boolean,
};
type Hex = {n: 0x01};
type T1 = { method: (a) => void };
type T2 = { method(a): void };
declare class X { method(a): void }
declare function f(a): void;
var f: (a) => void;
interface F1 { m(string): number }
interface F2 { m: (string) => number }
function f1(o: { f: (string) => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = (/* comment */ arg) => void;
type f5 = (arg /* comment */) => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: child_process$ChildProcess => FlowIDEConnection =
defaultIDEConnectionFactory,
) {
}
}
interface F {
ideConnectionFactoryLongLongLong: (child_process$ChildProcess) => FlowIDEConnection
}
type ExtractType = <A>(B<C>) => D
type T3 = ?(() => A);
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = (?() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ?(?(() => A));
type T8 = ?(?() => A) | B;
=====================================output=====================================
type Banana = {
eat: (string) => boolean,
};
type Hex = { n: 0x01 };
type T1 = { method: (a) => void };
type T2 = { method(a): void };
declare class X {
method(a): void;
}
declare function f(a): void;
var f: (a) => void;
interface F1 {
m(string): number;
}
interface F2 {
m: (string) => number;
}
function f1(o: { f: (string) => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = (/* comment */ arg) => void;
type f5 = (arg /* comment */) => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: (child_process$ChildProcess) => FlowIDEConnection = defaultIDEConnectionFactory,
) {}
}
interface F {
ideConnectionFactoryLongLongLong: (child_process$ChildProcess) => FlowIDEConnection;
}
type ExtractType = <A>(B<C>) => D;
type T3 = ?() => A;
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = ?(() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ??(() => A);
type T8 = ??(() => A) | B;
================================================================================
`;
@@ -209,277 +483,3 @@ type T8 = ??(() => A) | B;
================================================================================
`;
exports[`test.js format 2`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
type Banana = {
eat: string => boolean,
};
type Hex = {n: 0x01};
type T1 = { method: (a) => void };
type T2 = { method(a): void };
declare class X { method(a): void }
declare function f(a): void;
var f: (a) => void;
interface F1 { m(string): number }
interface F2 { m: (string) => number }
function f1(o: { f: (string) => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = (/* comment */ arg) => void;
type f5 = (arg /* comment */) => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: child_process$ChildProcess => FlowIDEConnection =
defaultIDEConnectionFactory,
) {
}
}
interface F {
ideConnectionFactoryLongLongLong: (child_process$ChildProcess) => FlowIDEConnection
}
type ExtractType = <A>(B<C>) => D
type T3 = ?(() => A);
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = (?() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ?(?(() => A));
type T8 = ?(?() => A) | B;
=====================================output=====================================
type Banana = {
eat: (string) => boolean,
};
type Hex = { n: 0x01 };
type T1 = { method: (a) => void };
type T2 = { method(a): void };
declare class X {
method(a): void;
}
declare function f(a): void;
var f: (a) => void;
interface F1 {
m(string): number;
}
interface F2 {
m: (string) => number;
}
function f1(o: { f: (string) => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = (/* comment */ arg) => void;
type f5 = (arg /* comment */) => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: (child_process$ChildProcess) => FlowIDEConnection = defaultIDEConnectionFactory,
) {}
}
interface F {
ideConnectionFactoryLongLongLong: (child_process$ChildProcess) => FlowIDEConnection;
}
type ExtractType = <A>(B<C>) => D;
type T3 = ?() => A;
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = ?(() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ??(() => A);
type T8 = ??(() => A) | B;
================================================================================
`;
exports[`test.js format 3`] = `
====================================options=====================================
arrowParens: "avoid"
parsers: ["flow", "babel"]
printWidth: 80
| printWidth
=====================================input======================================
type Banana = {
eat: string => boolean,
};
type Hex = {n: 0x01};
type T1 = { method: (a) => void };
type T2 = { method(a): void };
declare class X { method(a): void }
declare function f(a): void;
var f: (a) => void;
interface F1 { m(string): number }
interface F2 { m: (string) => number }
function f1(o: { f: (string) => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = (/* comment */ arg) => void;
type f5 = (arg /* comment */) => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: child_process$ChildProcess => FlowIDEConnection =
defaultIDEConnectionFactory,
) {
}
}
interface F {
ideConnectionFactoryLongLongLong: (child_process$ChildProcess) => FlowIDEConnection
}
type ExtractType = <A>(B<C>) => D
type T3 = ?(() => A);
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = (?() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ?(?(() => A));
type T8 = ?(?() => A) | B;
=====================================output=====================================
type Banana = {
eat: string => boolean,
};
type Hex = { n: 0x01 };
type T1 = { method: a => void };
type T2 = { method(a): void };
declare class X {
method(a): void;
}
declare function f(a): void;
var f: a => void;
interface F1 {
m(string): number;
}
interface F2 {
m: string => number;
}
function f1(o: { f: string => void }) {}
function f2(o: { f(string): void }) {}
type f3 = (...arg) => void;
type f4 = /* comment */ arg => void;
type f5 = arg /* comment */ => void;
type f6 = (?arg) => void;
class Y {
constructor(
ideConnectionFactory: child_process$ChildProcess => FlowIDEConnection = defaultIDEConnectionFactory
) {}
}
interface F {
ideConnectionFactoryLongLongLong: child_process$ChildProcess => FlowIDEConnection;
}
type ExtractType = <A>(B<C>) => D;
type T3 = ?() => A;
type T4 = ?(() => A) | B;
type T5 = ?() => A | B;
type T6 = ?(() => A) | B;
// https://github.com/babel/babel/issues/7924
//type T = ??() => A;
type T7 = ??(() => A);
type T8 = ??(() => A) | B;
================================================================================
`;
@@ -1,5 +1,40 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`break.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
var X = {
perform: function<
A, B, C, D, E, F, G,
T: (a: A, b: B, c: C, d: D, e: E, f: F) => G // eslint-disable-line space-before-function-paren
>(
method: T, scope: any,
a: A, b: B, c: C, d: D, e: E, f: F,
): G {
}
}
=====================================output=====================================
var X = {
perform: function <
A,
B,
C,
D,
E,
F,
G,
T: (a: A, b: B, c: C, d: D, e: E, f: F) => G, // eslint-disable-line space-before-function-paren
>(method: T, scope: any, a: A, b: B, c: C, d: D, e: E, f: F): G {},
};
================================================================================
`;
exports[`break.js format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
@@ -34,37 +69,19 @@ var X = {
================================================================================
`;
exports[`break.js format 2`] = `
exports[`generic.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
var X = {
perform: function<
A, B, C, D, E, F, G,
T: (a: A, b: B, c: C, d: D, e: E, f: F) => G // eslint-disable-line space-before-function-paren
>(
method: T, scope: any,
a: A, b: B, c: C, d: D, e: E, f: F,
): G {
}
}
const identity = <T>(t: T): T => t;
const a = 1;
=====================================output=====================================
var X = {
perform: function <
A,
B,
C,
D,
E,
F,
G,
T: (a: A, b: B, c: C, d: D, e: E, f: F) => G, // eslint-disable-line space-before-function-paren
>(method: T, scope: any, a: A, b: B, c: C, d: D, e: E, f: F): G {},
};
const identity = <T>(t: T): T => t;
const a = 1;
================================================================================
`;
@@ -85,19 +102,23 @@ const a = 1;
================================================================================
`;
exports[`generic.js format 2`] = `
exports[`interface.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
const identity = <T>(t: T): T => t;
const a = 1;
interface A { 'C': string; }
interface B { "D": boolean; }
=====================================output=====================================
const identity = <T>(t: T): T => t;
const a = 1;
interface A {
C: string;
}
interface B {
D: boolean;
}
================================================================================
`;
@@ -122,23 +143,33 @@ interface B {
================================================================================
`;
exports[`interface.js format 2`] = `
exports[`nullable.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
interface A { 'C': string; }
interface B { "D": boolean; }
function formatEntireFile(
fileVersion: FileVersion,
range: atom$Range,
): Promise<?{
newCursor?: number,
formatted: string,
}> {}
function foo(): Promise<?boolean> {}
=====================================output=====================================
interface A {
C: string;
}
interface B {
D: boolean;
}
function formatEntireFile(
fileVersion: FileVersion,
range: atom$Range,
): Promise<?{
newCursor?: number,
formatted: string,
}> {}
function foo(): Promise<?boolean> {}
================================================================================
`;
@@ -173,33 +204,17 @@ function foo(): Promise<?boolean> {}
================================================================================
`;
exports[`nullable.js format 2`] = `
exports[`single-identifier.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
function formatEntireFile(
fileVersion: FileVersion,
range: atom$Range,
): Promise<?{
newCursor?: number,
formatted: string,
}> {}
function foo(): Promise<?boolean> {}
const longVariableName: Array<number> = this.foo.bar.baz.collider.body.vertices.reduce();
=====================================output=====================================
function formatEntireFile(
fileVersion: FileVersion,
range: atom$Range,
): Promise<?{
newCursor?: number,
formatted: string,
}> {}
function foo(): Promise<?boolean> {}
const longVariableName: Array<number> = this.foo.bar.baz.collider.body.vertices.reduce();
================================================================================
`;
@@ -218,17 +233,29 @@ const longVariableName: Array<number> = this.foo.bar.baz.collider.body.vertices.
================================================================================
`;
exports[`single-identifier.js format 2`] = `
exports[`trailing.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
const longVariableName: Array<number> = this.foo.bar.baz.collider.body.vertices.reduce();
type State = {
errors: Immutable.Map<
Ahohohhohohohohohohohohohohooh,
Fbt | Immutable.Map<ErrorIndex, Fbt>
>,
shouldValidate: boolean,
};
=====================================output=====================================
const longVariableName: Array<number> = this.foo.bar.baz.collider.body.vertices.reduce();
type State = {
errors: Immutable.Map<
Ahohohhohohohohohohohohohohooh,
Fbt | Immutable.Map<ErrorIndex, Fbt>,
>,
shouldValidate: boolean,
};
================================================================================
`;
@@ -259,29 +286,21 @@ type State = {
================================================================================
`;
exports[`trailing.js format 2`] = `
exports[`type.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
type State = {
errors: Immutable.Map<
Ahohohhohohohohohohohohohohooh,
Fbt | Immutable.Map<ErrorIndex, Fbt>
>,
shouldValidate: boolean,
};
type F = <T>(T) => T;
type G = (<A, B>(A) => B);
type H = { 'A': string, "B": number };
=====================================output=====================================
type State = {
errors: Immutable.Map<
Ahohohhohohohohohohohohohohooh,
Fbt | Immutable.Map<ErrorIndex, Fbt>,
>,
shouldValidate: boolean,
};
type F = <T>(T) => T;
type G = <A, B>(A) => B;
type H = { A: string, B: number };
================================================================================
`;
@@ -304,21 +323,23 @@ type H = { A: string, B: number };
================================================================================
`;
exports[`type.js format 2`] = `
exports[`union.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
type F = <T>(T) => T;
type G = (<A, B>(A) => B);
type H = { 'A': string, "B": number };
type Foo = Promise<
{ ok: true, bar: string, baz: SomeOtherLongType } |
{ ok: false, bar: SomeOtherLongType }
>;
=====================================output=====================================
type F = <T>(T) => T;
type G = <A, B>(A) => B;
type H = { A: string, B: number };
type Foo = Promise<
| { ok: true, bar: string, baz: SomeOtherLongType }
| { ok: false, bar: SomeOtherLongType },
>;
================================================================================
`;
@@ -342,24 +363,3 @@ type Foo = Promise<
================================================================================
`;
exports[`union.js format 2`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
type Foo = Promise<
{ ok: true, bar: string, baz: SomeOtherLongType } |
{ ok: false, bar: SomeOtherLongType }
>;
=====================================output=====================================
type Foo = Promise<
| { ok: true, bar: string, baz: SomeOtherLongType }
| { ok: false, bar: SomeOtherLongType },
>;
================================================================================
`;
@@ -1,276 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`comments.js format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "es5"
| printWidth
=====================================input======================================
// @flow
type Foo = {
// comment
...,
};
type Foo = {
/* comment */
...,
};
type Foo = { /* comment */ ... };
type Foo = { /* comment */
...};
type Foo = {
// comment0
// comment1
...,
};
type Foo = {
/* comment0 */
/* comment1 */
...,
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
=====================================output=====================================
// @flow
type Foo = {
// comment
...
};
type Foo = {
/* comment */
...
};
type Foo = { /* comment */ ... };
type Foo = {
/* comment */
...
};
type Foo = {
// comment0
// comment1
...
};
type Foo = {
/* comment0 */
/* comment1 */
...
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
================================================================================
`;
exports[`comments.js format 2`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
// @flow
type Foo = {
// comment
...,
};
type Foo = {
/* comment */
...,
};
type Foo = { /* comment */ ... };
type Foo = { /* comment */
...};
type Foo = {
// comment0
// comment1
...,
};
type Foo = {
/* comment0 */
/* comment1 */
...,
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
=====================================output=====================================
// @flow
type Foo = {
// comment
...
};
type Foo = {
/* comment */
...
};
type Foo = { /* comment */ ... };
type Foo = {
/* comment */
...
};
type Foo = {
// comment0
// comment1
...
};
type Foo = {
/* comment0 */
/* comment1 */
...
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
================================================================================
`;
exports[`comments.js format 3`] = `
exports[`comments.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
@@ -405,7 +135,390 @@ type Foo = {
================================================================================
`;
exports[`test.js format 1`] = `
exports[`comments.js - {"trailingComma":"es5"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "es5"
| printWidth
=====================================input======================================
// @flow
type Foo = {
// comment
...,
};
type Foo = {
/* comment */
...,
};
type Foo = { /* comment */ ... };
type Foo = { /* comment */
...};
type Foo = {
// comment0
// comment1
...,
};
type Foo = {
/* comment0 */
/* comment1 */
...,
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
=====================================output=====================================
// @flow
type Foo = {
// comment
...
};
type Foo = {
/* comment */
...
};
type Foo = { /* comment */ ... };
type Foo = {
/* comment */
...
};
type Foo = {
// comment0
// comment1
...
};
type Foo = {
/* comment0 */
/* comment1 */
...
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
================================================================================
`;
exports[`comments.js - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
// @flow
type Foo = {
// comment
...,
};
type Foo = {
/* comment */
...,
};
type Foo = { /* comment */ ... };
type Foo = { /* comment */
...};
type Foo = {
// comment0
// comment1
...,
};
type Foo = {
/* comment0 */
/* comment1 */
...,
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
=====================================output=====================================
// @flow
type Foo = {
// comment
...
};
type Foo = {
/* comment */
...
};
type Foo = { /* comment */ ... };
type Foo = {
/* comment */
...
};
type Foo = {
// comment0
// comment1
...
};
type Foo = {
/* comment0 */
/* comment1 */
...
};
type Foo = {
// comment
foo: string,
...
};
type Foo = {
// comment0
// comment1
foo: string,
...
};
type Foo = {
/* comment */
foo: string,
...
};
type Foo = {
/* comment */
[string]: string,
...
};
type Foo = {
/* comment0 */
/* comment1 */
foo: string,
...
};
================================================================================
`;
exports[`test.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
//@flow
type T = {
a: number,
...,
}
type I = {
[string]: number,
...,
}
type U = { a: number, b: number, c: number, d: number, e: number, f: number, g: number, ...};
type V = {x: {...}, y: {x: {...}, a: number, b: number, c: number, d: number, e: number, f: number, ...}, z: {...}, foo: number, bar: {foo: number, ...}, ...};
function test(x: {foo: number, bar: number, baz: number, qux: nunber, a: number, b: number, c: {a: number, ...}, ...}) { return x; }
function test(x: {foo: number, bar: number, baz: number, qux: nunber, a: number, b: number, c: {a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, ...}, ...}) { return x; }
type W = {...};
type X = {
...,
};
=====================================output=====================================
//@flow
type T = {
a: number,
...
};
type I = {
[string]: number,
...
};
type U = {
a: number,
b: number,
c: number,
d: number,
e: number,
f: number,
g: number,
...
};
type V = {
x: { ... },
y: {
x: { ... },
a: number,
b: number,
c: number,
d: number,
e: number,
f: number,
...
},
z: { ... },
foo: number,
bar: { foo: number, ... },
...
};
function test(x: {
foo: number,
bar: number,
baz: number,
qux: nunber,
a: number,
b: number,
c: { a: number, ... },
...
}) {
return x;
}
function test(x: {
foo: number,
bar: number,
baz: number,
qux: nunber,
a: number,
b: number,
c: {
a: number,
b: number,
c: number,
d: number,
e: number,
f: number,
g: number,
h: number,
i: number,
...
},
...
}) {
return x;
}
type W = { ... };
type X = { ... };
================================================================================
`;
exports[`test.js - {"trailingComma":"es5"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
@@ -518,7 +631,7 @@ type X = { ... };
================================================================================
`;
exports[`test.js format 2`] = `
exports[`test.js - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
@@ -630,116 +743,3 @@ type X = { ... };
================================================================================
`;
exports[`test.js format 3`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
//@flow
type T = {
a: number,
...,
}
type I = {
[string]: number,
...,
}
type U = { a: number, b: number, c: number, d: number, e: number, f: number, g: number, ...};
type V = {x: {...}, y: {x: {...}, a: number, b: number, c: number, d: number, e: number, f: number, ...}, z: {...}, foo: number, bar: {foo: number, ...}, ...};
function test(x: {foo: number, bar: number, baz: number, qux: nunber, a: number, b: number, c: {a: number, ...}, ...}) { return x; }
function test(x: {foo: number, bar: number, baz: number, qux: nunber, a: number, b: number, c: {a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, ...}, ...}) { return x; }
type W = {...};
type X = {
...,
};
=====================================output=====================================
//@flow
type T = {
a: number,
...
};
type I = {
[string]: number,
...
};
type U = {
a: number,
b: number,
c: number,
d: number,
e: number,
f: number,
g: number,
...
};
type V = {
x: { ... },
y: {
x: { ... },
a: number,
b: number,
c: number,
d: number,
e: number,
f: number,
...
},
z: { ... },
foo: number,
bar: { foo: number, ... },
...
};
function test(x: {
foo: number,
bar: number,
baz: number,
qux: nunber,
a: number,
b: number,
c: { a: number, ... },
...
}) {
return x;
}
function test(x: {
foo: number,
bar: number,
baz: number,
qux: nunber,
a: number,
b: number,
c: {
a: number,
b: number,
c: number,
d: number,
e: number,
f: number,
g: number,
h: number,
i: number,
...
},
...
}) {
return x;
}
type W = { ... };
type X = { ... };
================================================================================
`;
@@ -1,5 +1,42 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`order.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
type Foo = {
// a
alpha: 'hello',
// b
[key: string]: void,
// c
beta: 10,
// d
}
=====================================output=====================================
type Foo = {
// a
alpha: "hello",
// b
[key: string]: void,
// c
beta: 10,
// d
};
================================================================================
`;
exports[`order.js format 1`] = `
====================================options=====================================
parsers: ["flow"]
@@ -35,40 +72,3 @@ type Foo = {
================================================================================
`;
exports[`order.js format 2`] = `
====================================options=====================================
parsers: ["flow"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
type Foo = {
// a
alpha: 'hello',
// b
[key: string]: void,
// c
beta: 10,
// d
}
=====================================output=====================================
type Foo = {
// a
alpha: "hello",
// b
[key: string]: void,
// c
beta: 10,
// d
};
================================================================================
`;
@@ -1,5 +1,22 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`param.js - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
const f = ({}: MyVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryLongType) => {};
function g({}: Foo) {}
=====================================output=====================================
const f = ({}: MyVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryLongType) => {};
function g({}: Foo) {}
================================================================================
`;
exports[`param.js format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
@@ -15,20 +32,3 @@ function g({}: Foo) {}
================================================================================
`;
exports[`param.js format 2`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
const f = ({}: MyVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryLongType) => {};
function g({}: Foo) {}
=====================================output=====================================
const f = ({}: MyVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryLongType) => {};
function g({}: Foo) {}
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`quotes.js format 1`] = `
exports[`quotes.js - {"quoteProps":"consistent"} format 1`] = `
====================================options=====================================
parsers: ["flow"]
printWidth: 80
@@ -1,5 +1,20 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`declare_export.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
declare export default 5;
=====================================output=====================================
declare export default 5
================================================================================
`;
exports[`declare_export.js format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
@@ -14,17 +29,17 @@ declare export default 5;
================================================================================
`;
exports[`declare_export.js format 2`] = `
exports[`declare_type.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
declare export default 5;
declare type A = string;
=====================================output=====================================
declare export default 5
declare type A = string
================================================================================
`;
@@ -43,17 +58,17 @@ declare type A = string;
================================================================================
`;
exports[`declare_type.js format 2`] = `
exports[`declare_var.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
declare type A = string;
declare var bool: React$PropType$Primitive<boolean>;
=====================================output=====================================
declare type A = string
declare var bool: React$PropType$Primitive<boolean>
================================================================================
`;
@@ -72,17 +87,31 @@ declare var bool: React$PropType$Primitive<boolean>;
================================================================================
`;
exports[`declare_var.js format 2`] = `
exports[`long.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
declare var bool: React$PropType$Primitive<boolean>;
export type AdamPlacementValidationSingleErrorKey =
'SOME_FANCY_TARGETS.GLOBAL_TARGET';
export type SomeReallyLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = true;
export type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = null;
type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey2 = SomeReallyLongLongLongLongLongLongIdentifier;
=====================================output=====================================
declare var bool: React$PropType$Primitive<boolean>
export type AdamPlacementValidationSingleErrorKey =
"SOME_FANCY_TARGETS.GLOBAL_TARGET"
export type SomeReallyLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = true
export type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = null
type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey2 = SomeReallyLongLongLongLongLongLongIdentifier
================================================================================
`;
@@ -115,31 +144,43 @@ type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey2 = Som
================================================================================
`;
exports[`long.js format 2`] = `
exports[`opaque.js - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
export type AdamPlacementValidationSingleErrorKey =
'SOME_FANCY_TARGETS.GLOBAL_TARGET';
export type SomeReallyLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = true;
export type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = null;
type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey2 = SomeReallyLongLongLongLongLongLongIdentifier;
declare export opaque type Foo;
declare export opaque type Bar<T>;
declare export opaque type Baz: Foo;
declare export opaque type Foo1<T>: Bar<T>;
declare export opaque type Foo2<T>: Bar;
declare export opaque type Foo3: Bar<T>;
opaque type ID = string;
opaque type Foo4<T> = Bar<T>;
opaque type Maybe<T> = _Maybe<T, *>;
export opaque type Foo5 = number;
opaque type union =
| {type: "A"}
| {type: "B"};
opaque type overloads =
& ((x: string) => number)
& ((x: number) => string);
=====================================output=====================================
export type AdamPlacementValidationSingleErrorKey =
"SOME_FANCY_TARGETS.GLOBAL_TARGET"
export type SomeReallyLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = true
export type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey = null
type SomeOtherLongLongLongLongLongLongLongLongLongLongLongLongLongLongKey2 = SomeReallyLongLongLongLongLongLongIdentifier
declare export opaque type Foo
declare export opaque type Bar<T>
declare export opaque type Baz: Foo
declare export opaque type Foo1<T>: Bar<T>
declare export opaque type Foo2<T>: Bar
declare export opaque type Foo3: Bar<T>
opaque type ID = string
opaque type Foo4<T> = Bar<T>
opaque type Maybe<T> = _Maybe<T, *>
export opaque type Foo5 = number
opaque type union = { type: "A" } | { type: "B" }
opaque type overloads = ((x: string) => number) & ((x: number) => string)
================================================================================
`;
@@ -183,44 +224,3 @@ opaque type overloads = ((x: string) => number) & ((x: number) => string);
================================================================================
`;
exports[`opaque.js format 2`] = `
====================================options=====================================
parsers: ["flow", "babel"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
declare export opaque type Foo;
declare export opaque type Bar<T>;
declare export opaque type Baz: Foo;
declare export opaque type Foo1<T>: Bar<T>;
declare export opaque type Foo2<T>: Bar;
declare export opaque type Foo3: Bar<T>;
opaque type ID = string;
opaque type Foo4<T> = Bar<T>;
opaque type Maybe<T> = _Maybe<T, *>;
export opaque type Foo5 = number;
opaque type union =
| {type: "A"}
| {type: "B"};
opaque type overloads =
& ((x: string) => number)
& ((x: number) => string);
=====================================output=====================================
declare export opaque type Foo
declare export opaque type Bar<T>
declare export opaque type Baz: Foo
declare export opaque type Foo1<T>: Bar<T>
declare export opaque type Foo2<T>: Bar
declare export opaque type Foo3: Bar<T>
opaque type ID = string
opaque type Foo4<T> = Bar<T>
opaque type Maybe<T> = _Maybe<T, *>
export opaque type Foo5 = number
opaque type union = { type: "A" } | { type: "B" }
opaque type overloads = ((x: string) => number) & ((x: number) => string)
================================================================================
`;
@@ -1,5 +1,28 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`bracket_spacing.graphql - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["graphql"]
printWidth: 80
| printWidth
=====================================input======================================
fragment Visit on HighlightedVisit
@argumentDefinitions(
count: {type: "Int", defaultValue: 20}
) {
name
}
=====================================output=====================================
fragment Visit on HighlightedVisit
@argumentDefinitions(count: {type: "Int", defaultValue: 20}) {
name
}
================================================================================
`;
exports[`bracket_spacing.graphql format 1`] = `
====================================options=====================================
parsers: ["graphql"]
@@ -21,26 +44,3 @@ fragment Visit on HighlightedVisit
================================================================================
`;
exports[`bracket_spacing.graphql format 2`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["graphql"]
printWidth: 80
| printWidth
=====================================input======================================
fragment Visit on HighlightedVisit
@argumentDefinitions(
count: {type: "Int", defaultValue: 20}
) {
name
}
=====================================output=====================================
fragment Visit on HighlightedVisit
@argumentDefinitions(count: {type: "Int", defaultValue: 20}) {
name
}
================================================================================
`;
@@ -1,66 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`trailing.graphql format 1`] = `
====================================options=====================================
parsers: ["graphql"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
query Query(
$pageID: ID!
$scale: Float
$PROJECT_UNIT_PROFILE_PICTURE_SIZE: Int
$PROJECT_UNIT_CARD_SIZE: Int
) @argumentDefinitions(
count: {type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}
test: [{type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}]
) {
cover_photo {
image(
width: $PROJECT_UNIT_CARD_SIZE,
height: $PROJECT_UNIT_CARD_SIZE,
sizing: "cover-fill",
scale: $scale,
) {
uri
}
}
}
=====================================output=====================================
query Query(
$pageID: ID!
$scale: Float
$PROJECT_UNIT_PROFILE_PICTURE_SIZE: Int
$PROJECT_UNIT_CARD_SIZE: Int
)
@argumentDefinitions(
count: {
type: "Int"
defaultValue: 20
someSuperSuperSuperSuperLongType: 301
}
test: [
{ type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301 }
]
) {
cover_photo {
image(
width: $PROJECT_UNIT_CARD_SIZE
height: $PROJECT_UNIT_CARD_SIZE
sizing: "cover-fill"
scale: $scale
) {
uri
}
}
}
================================================================================
`;
exports[`trailing.graphql format 2`] = `
exports[`trailing.graphql - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["graphql"]
printWidth: 80
@@ -120,7 +60,67 @@ query Query(
================================================================================
`;
exports[`trailing.graphql format 3`] = `
exports[`trailing.graphql - {"trailingComma":"none"} format 1`] = `
====================================options=====================================
parsers: ["graphql"]
printWidth: 80
trailingComma: "none"
| printWidth
=====================================input======================================
query Query(
$pageID: ID!
$scale: Float
$PROJECT_UNIT_PROFILE_PICTURE_SIZE: Int
$PROJECT_UNIT_CARD_SIZE: Int
) @argumentDefinitions(
count: {type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}
test: [{type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}]
) {
cover_photo {
image(
width: $PROJECT_UNIT_CARD_SIZE,
height: $PROJECT_UNIT_CARD_SIZE,
sizing: "cover-fill",
scale: $scale,
) {
uri
}
}
}
=====================================output=====================================
query Query(
$pageID: ID!
$scale: Float
$PROJECT_UNIT_PROFILE_PICTURE_SIZE: Int
$PROJECT_UNIT_CARD_SIZE: Int
)
@argumentDefinitions(
count: {
type: "Int"
defaultValue: 20
someSuperSuperSuperSuperLongType: 301
}
test: [
{ type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301 }
]
) {
cover_photo {
image(
width: $PROJECT_UNIT_CARD_SIZE
height: $PROJECT_UNIT_CARD_SIZE
sizing: "cover-fill"
scale: $scale
) {
uri
}
}
}
================================================================================
`;
exports[`trailing.graphql format 1`] = `
====================================options=====================================
parsers: ["graphql"]
printWidth: 80
@@ -1,5 +1,25 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`brackets.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div title='My title'></div>
<div title="My title"></div>
<div title='My "title"'></div>
<div title="My other 'title'"></div>
=====================================output=====================================
<div title='My title'></div>
<div title='My title'></div>
<div title='My "title"'></div>
<div title="My other 'title'"></div>
================================================================================
`;
exports[`brackets.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -18,23 +38,3 @@ printWidth: 80
<div title="My other 'title'"></div>
================================================================================
`;
exports[`brackets.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div title='My title'></div>
<div title="My title"></div>
<div title='My "title"'></div>
<div title="My other 'title'"></div>
=====================================output=====================================
<div title='My title'></div>
<div title='My title'></div>
<div title='My "title"'></div>
<div title="My other 'title'"></div>
================================================================================
`;
@@ -1,5 +1,80 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`component.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<UserGreeting @name="Ricardo" @greeting="Olá" />
{{@greeting}}, {{@name}}!
<div>
<UserGreeting
@aVeryLongArgumentNameThatIsStillGoing={{@alsoAVeryLongArgument}}
/>
</div>
<Form as |f|>
<f.input @title="hello" />
<f.input>hello</f.input>
</Form>
<this.label @title="hello" />
<button onclick={{action next}}>Next</button>
<button disabled class="disabled"></button>
<button disabled=disabled class="disabled"></button>
<img alt="" />
<div ...attributes>Hello</div>
<ul class="list-unstyled
one-tab">
</ul>
=====================================output=====================================
<UserGreeting @name='Ricardo' @greeting='Olá' />
{{@greeting}}, {{@name}}!
<div>
<UserGreeting
@aVeryLongArgumentNameThatIsStillGoing={{@alsoAVeryLongArgument}}
/>
</div>
<Form as |f|>
<f.input @title='hello' />
<f.input>
hello
</f.input>
</Form>
<this.label @title='hello' />
<button onclick={{action next}}>
Next
</button>
<button disabled class='disabled'></button>
<button disabled='disabled' class='disabled'></button>
<img alt='' />
<div ...attributes>
Hello
</div>
<ul class='list-unstyled
one-tab'>
</ul>
================================================================================
`;
exports[`component.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -74,78 +149,29 @@ printWidth: 80
================================================================================
`;
exports[`component.hbs format 2`] = `
exports[`literals.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<UserGreeting @name="Ricardo" @greeting="Olá" />
{{@greeting}}, {{@name}}!
{{mustache true}}
{{mustache 5}}
{{mustache undefined}}
{{mustache null}}
<!-- hello world -->
{{! Mustache Comment}}
{{!-- Mustache Comment }} --}}
<div>
<UserGreeting
@aVeryLongArgumentNameThatIsStillGoing={{@alsoAVeryLongArgument}}
/>
</div>
<Form as |f|>
<f.input @title="hello" />
<f.input>hello</f.input>
</Form>
<this.label @title="hello" />
<button onclick={{action next}}>Next</button>
<button disabled class="disabled"></button>
<button disabled=disabled class="disabled"></button>
<img alt="" />
<div ...attributes>Hello</div>
<ul class="list-unstyled
one-tab">
</ul>
=====================================output=====================================
<UserGreeting @name='Ricardo' @greeting='Olá' />
{{@greeting}}, {{@name}}!
<div>
<UserGreeting
@aVeryLongArgumentNameThatIsStillGoing={{@alsoAVeryLongArgument}}
/>
</div>
<Form as |f|>
<f.input @title='hello' />
<f.input>
hello
</f.input>
</Form>
<this.label @title='hello' />
<button onclick={{action next}}>
Next
</button>
<button disabled class='disabled'></button>
<button disabled='disabled' class='disabled'></button>
<img alt='' />
<div ...attributes>
Hello
</div>
<ul class='list-unstyled
one-tab'>
</ul>
{{mustache true}}
{{mustache 5}}
{{mustache undefined}}
{{mustache null}}
<!-- hello world -->
{{! Mustache Comment}}
{{!-- Mustache Comment }} --}}
================================================================================
`;
@@ -174,29 +200,35 @@ printWidth: 80
================================================================================
`;
exports[`literals.hbs format 2`] = `
exports[`nested-path.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
{{mustache true}}
{{mustache 5}}
{{mustache undefined}}
{{mustache null}}
<!-- hello world -->
{{! Mustache Comment}}
{{!-- Mustache Comment }} --}}
<div class="entry">
<h1>{{title}}</h1>
<h2>By {{author.name}}</h2>
<div class="body">
{{body}}
</div>
</div>
=====================================output=====================================
{{mustache true}}
{{mustache 5}}
{{mustache undefined}}
{{mustache null}}
<!-- hello world -->
{{! Mustache Comment}}
{{!-- Mustache Comment }} --}}
<div class='entry'>
<h1>
{{title}}
</h1>
<h2>
By {{author.name}}
</h2>
<div class='body'>
{{body}}
</div>
</div>
================================================================================
`;
@@ -231,35 +263,19 @@ printWidth: 80
================================================================================
`;
exports[`nested-path.hbs format 2`] = `
exports[`raw.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div class="entry">
<h1>{{title}}</h1>
<h2>By {{author.name}}</h2>
<div class="body">
{{body}}
</div>
</div>
<p>{{{raw}}}</p>
=====================================output=====================================
<div class='entry'>
<h1>
{{title}}
</h1>
<h2>
By {{author.name}}
</h2>
<div class='body'>
{{body}}
</div>
</div>
<p>
{{{raw}}}
</p>
================================================================================
`;
@@ -278,19 +294,27 @@ printWidth: 80
================================================================================
`;
exports[`raw.hbs format 2`] = `
exports[`string-literals.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<p>{{{raw}}}</p>
{{"abc"}}
{{'abc'}}
{{" \\" \\" ' more double quote than single quote "}}
{{' \\' \\' " more single quote than double quote '}}
{{' " \\' \\" \\\\ '}}
{{" \\" \\' ' \\\\ "}}
=====================================output=====================================
<p>
{{{raw}}}
</p>
{{'abc'}}
{{'abc'}}
{{' " " \\' more double quote than single quote '}}
{{" ' ' \\" more single quote than double quote "}}
{{' " \\' \\" \\\\ '}}
{{" \\" \\' ' \\\\ "}}
================================================================================
`;
@@ -316,27 +340,3 @@ printWidth: 80
{{" \\" \\' ' \\\\ "}}
================================================================================
`;
exports[`string-literals.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
{{"abc"}}
{{'abc'}}
{{" \\" \\" ' more double quote than single quote "}}
{{' \\' \\' " more single quote than double quote '}}
{{' " \\' \\" \\\\ '}}
{{" \\" \\' ' \\\\ "}}
=====================================output=====================================
{{'abc'}}
{{'abc'}}
{{' " " \\' more double quote than single quote '}}
{{" ' ' \\" more single quote than double quote "}}
{{' " \\' \\" \\\\ '}}
{{" \\" \\' ' \\\\ "}}
================================================================================
`;
@@ -1,5 +1,163 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`block-statement.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
{{#block param hashKey=hashValue as |blockParam|}}
Hello
{{/block}}
{{#block almost80CharacterLongPositionalParamThatIsFirstAlmost80Chars helloWorldParam key=here}}
{{/block}}
{{#block param param param param param param param hashKey=hashValue as |blockParam|}}
Hello
{{/block}}
{{#block param param param param param param param hashKey=HashValue hashKey=hashValue}}
Hello
{{/block}}
{{#block param param param param param param param param param param param param param}}
Hello
{{/block}}
{{#block hashKey=HashValue hashKey=hashValue hashKey=HashValue hashKey=hashValue hashKey=HashValue}}
Hello
{{/block}}
{{#block}}
{{#block}}
hello
{{/block}}
{{/block}}
{{#block}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block param}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block}}
hello
{{/block}}
<MyComponent as |firstName|>
{{firstName}}
</MyComponent>
<MyComponent as |firstName lastName|>
{{firstName}} {{lastName}}
</MyComponent>
=====================================output=====================================
{{#block param hashKey=hashValue as |blockParam|}}
Hello
{{/block}}
{{#block
almost80CharacterLongPositionalParamThatIsFirstAlmost80Chars
helloWorldParam
key=here
}}{{/block}}
{{#block
param
param
param
param
param
param
param
hashKey=hashValue as |blockParam|
}}
Hello
{{/block}}
{{#block
param
param
param
param
param
param
param
hashKey=HashValue
hashKey=hashValue
}}
Hello
{{/block}}
{{#block
param
param
param
param
param
param
param
param
param
param
param
param
param
}}
Hello
{{/block}}
{{#block
hashKey=HashValue
hashKey=hashValue
hashKey=HashValue
hashKey=hashValue
hashKey=HashValue
}}
Hello
{{/block}}
{{#block}}
{{#block}}
hello
{{/block}}
{{/block}}
{{#block}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block param}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block}}
hello
{{/block}}
<MyComponent as |firstName|>
{{firstName}}
</MyComponent>
<MyComponent as |firstName lastName|>
{{firstName}} {{lastName}}
</MyComponent>
================================================================================
`;
exports[`block-statement.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -157,161 +315,33 @@ printWidth: 80
================================================================================
`;
exports[`block-statement.hbs format 2`] = `
exports[`each.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
{{#block param hashKey=hashValue as |blockParam|}}
Hello
{{/block}}
{{#block almost80CharacterLongPositionalParamThatIsFirstAlmost80Chars helloWorldParam key=here}}
{{/block}}
{{#block param param param param param param param hashKey=hashValue as |blockParam|}}
Hello
{{/block}}
{{#block param param param param param param param hashKey=HashValue hashKey=hashValue}}
Hello
{{/block}}
{{#block param param param param param param param param param param param param param}}
Hello
{{/block}}
{{#block hashKey=HashValue hashKey=hashValue hashKey=HashValue hashKey=hashValue hashKey=HashValue}}
Hello
{{/block}}
{{#block}}
{{#block}}
hello
{{/block}}
{{/block}}
{{#block}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block param}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block}}
hello
{{/block}}
<MyComponent as |firstName|>
{{firstName}}
</MyComponent>
<MyComponent as |firstName lastName|>
{{firstName}} {{lastName}}
</MyComponent>
<div id="comments">
{{#each comments}}
<h2><a href="/posts/{{permalink}}#{{id}}">{{title}}</a></h2>
<div>{{body}}</div>
{{/each}}
</div>
=====================================output=====================================
{{#block param hashKey=hashValue as |blockParam|}}
Hello
{{/block}}
{{#block
almost80CharacterLongPositionalParamThatIsFirstAlmost80Chars
helloWorldParam
key=here
}}{{/block}}
{{#block
param
param
param
param
param
param
param
hashKey=hashValue as |blockParam|
}}
Hello
{{/block}}
{{#block
param
param
param
param
param
param
param
hashKey=HashValue
hashKey=hashValue
}}
Hello
{{/block}}
{{#block
param
param
param
param
param
param
param
param
param
param
param
param
param
}}
Hello
{{/block}}
{{#block
hashKey=HashValue
hashKey=hashValue
hashKey=HashValue
hashKey=hashValue
hashKey=HashValue
}}
Hello
{{/block}}
{{#block}}
{{#block}}
hello
{{/block}}
{{/block}}
{{#block}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block param}}
{{#block param}}
hello
{{/block}}
{{/block}}
{{#block}}
hello
{{/block}}
<MyComponent as |firstName|>
{{firstName}}
</MyComponent>
<MyComponent as |firstName lastName|>
{{firstName}} {{lastName}}
</MyComponent>
<div id='comments'>
{{#each comments}}
<h2>
<a href="/posts/{{permalink}}#{{id}}">
{{title}}
</a>
</h2>
<div>
{{body}}
</div>
{{/each}}
</div>
================================================================================
`;
@@ -344,33 +374,225 @@ printWidth: 80
================================================================================
`;
exports[`each.hbs format 2`] = `
exports[`if-else.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div id="comments">
{{#each comments}}
<h2><a href="/posts/{{permalink}}#{{id}}">{{title}}</a></h2>
<div>{{body}}</div>
{{/each}}
<h1>
{{#if isAtWork}}
Ship that code!
{{else if isReading}}
You can finish War and Peace eventually...
{{else}}
Go to bed!
{{/if}}
</h1>
<h2>
{{#if a}}
A
{{else}}
B
{{/if}}
</h2>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else}}
hello
{{#if f}}
g
{{/if}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else if e}}
f
{{else if g}}
h
{{else}}
j
{{/if}}
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
=====================================output=====================================
<div id='comments'>
{{#each comments}}
<h2>
<a href="/posts/{{permalink}}#{{id}}">
{{title}}
</a>
</h2>
<div>
{{body}}
</div>
{{/each}}
<div>
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
</div>
{{#if a}}
b
{{else}}
{{#each c as |d|}}
e
{{/each}}
{{/if}}
{{#if a}}
{{#if b}}
ab
{{else if c}}
ac
{{/if}}
{{/if}}
{{#if a}}
a
<div>b</div>
c
{{else}}
{{#if c}}
a
b
<div>c</div>
{{/if}}
<div>a</div>
b
c
{{/if}}
=====================================output=====================================
<h1>
{{#if isAtWork}}
Ship that code!
{{else if isReading}}
You can finish War and Peace eventually...
{{else}}
Go to bed!
{{/if}}
</h1>
<h2>
{{#if a}}
A
{{else}}
B
{{/if}}
</h2>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else}}
hello
{{#if f}}
g
{{/if}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else if e}}
f
{{else if g}}
h
{{else}}
j
{{/if}}
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
<div>
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
</div>
{{#if a}}
b
{{else}}
{{#each c as |d|}}
e
{{/each}}
{{/if}}
{{#if a}}
{{#if b}}
ab
{{else if c}}
ac
{{/if}}
{{/if}}
{{#if a}}
a
<div>
b
</div>
c
{{else}}
{{#if c}}
a
b
<div>
c
</div>
{{/if}}
<div>
a
</div>
b
c
{{/if}}
================================================================================
`;
@@ -595,225 +817,27 @@ printWidth: 80
================================================================================
`;
exports[`if-else.hbs format 2`] = `
exports[`loop.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<h1>
{{#if isAtWork}}
Ship that code!
{{else if isReading}}
You can finish War and Peace eventually...
{{else}}
Go to bed!
{{/if}}
</h1>
<h2>
{{#if a}}
A
{{else}}
B
{{/if}}
</h2>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else}}
hello
{{#if f}}
g
{{/if}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else if e}}
f
{{else if g}}
h
{{else}}
j
{{/if}}
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
<div>
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
</div>
{{#if a}}
b
{{else}}
{{#each c as |d|}}
e
<ul>
{{#each speakers key="@index" as |speaker|}}
<li>{{speaker}}</li>
{{/each}}
{{/if}}
{{#if a}}
{{#if b}}
ab
{{else if c}}
ac
{{/if}}
{{/if}}
{{#if a}}
a
<div>b</div>
c
{{else}}
{{#if c}}
a
b
<div>c</div>
{{/if}}
<div>a</div>
b
c
{{/if}}
</ul>
=====================================output=====================================
<h1>
{{#if isAtWork}}
Ship that code!
{{else if isReading}}
You can finish War and Peace eventually...
{{else}}
Go to bed!
{{/if}}
</h1>
<h2>
{{#if a}}
A
{{else}}
B
{{/if}}
</h2>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else}}
hello
{{#if f}}
g
{{/if}}
e
{{/if}}
{{#if a}}
b
{{else if c}}
d
{{else if e}}
f
{{else if g}}
h
{{else}}
j
{{/if}}
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
<div>
<div>
{{#if a}}
b
{{else if c}}
d
{{else}}
e
{{/if}}
</div>
</div>
{{#if a}}
b
{{else}}
{{#each c as |d|}}
e
<ul>
{{#each speakers key='@index' as |speaker|}}
<li>
{{speaker}}
</li>
{{/each}}
{{/if}}
{{#if a}}
{{#if b}}
ab
{{else if c}}
ac
{{/if}}
{{/if}}
{{#if a}}
a
<div>
b
</div>
c
{{else}}
{{#if c}}
a
b
<div>
c
</div>
{{/if}}
<div>
a
</div>
b
c
{{/if}}
</ul>
================================================================================
`;
@@ -839,27 +863,3 @@ printWidth: 80
</ul>
================================================================================
`;
exports[`loop.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<ul>
{{#each speakers key="@index" as |speaker|}}
<li>{{speaker}}</li>
{{/each}}
</ul>
=====================================output=====================================
<ul>
{{#each speakers key='@index' as |speaker|}}
<li>
{{speaker}}
</li>
{{/each}}
</ul>
================================================================================
`;
@@ -1,5 +1,60 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`concat-statement.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div class="hello {{if goodbye true}}">
Hello
</div>
<div class="hello {{if goodbye true}} {{if goodbye false}} {{if goodbye true}} {{if goodbye false}} {{if goodbye true}}">
Hello
</div>
<a href="/{{url}}/{{url}}"></a>
<div class=" class-a{{myClass}}"></div>
<div class=" class-b {{myClass}}"></div>
<div class=" {{myClass}}class-c"></div>
<div class=" {{myClass}} class-d"></div>
<div class=" class-e{{myClass}} class-f"></div>
<div class=" class-g{{myClass}}class-h "></div>
<div class=" class-i {{myClass}}class-j"></div>
<div class="class-k {{myClass}} class-l"></div>
<div class=" class-m {{myClass}} class-n {{myClass}}class-o "></div>
<div class=" class-p class-q"></div>
=====================================output=====================================
<div class="hello {{if goodbye true}}">
Hello
</div>
<div
class="hello {{if goodbye true}} {{if goodbye false}} {{if goodbye true}} {{
if goodbye false
}} {{if goodbye true}}"
>
Hello
</div>
<a href="/{{url}}/{{url}}"></a>
<div class="class-a{{myClass}}"></div>
<div class="class-b {{myClass}}"></div>
<div class="{{myClass}}class-c"></div>
<div class="{{myClass}} class-d"></div>
<div class="class-e{{myClass}} class-f"></div>
<div class="class-g{{myClass}}class-h"></div>
<div class="class-i {{myClass}}class-j"></div>
<div class="class-k {{myClass}} class-l"></div>
<div class="class-m {{myClass}} class-n {{myClass}}class-o"></div>
<div class='class-p class-q'></div>
================================================================================
`;
exports[`concat-statement.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -54,58 +109,43 @@ printWidth: 80
================================================================================
`;
exports[`concat-statement.hbs format 2`] = `
exports[`in-attr-node.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div class="hello {{if goodbye true}}">
Hello
</div>
<div class="hello {{if goodbye true}} {{if goodbye false}} {{if goodbye true}} {{if goodbye false}} {{if goodbye true}}">
Hello
</div>
<a href="/{{url}}/{{url}}"></a>
<div class=" class-a{{myClass}}"></div>
<div class=" class-b {{myClass}}"></div>
<div class=" {{myClass}}class-c"></div>
<div class=" {{myClass}} class-d"></div>
<div class=" class-e{{myClass}} class-f"></div>
<div class=" class-g{{myClass}}class-h "></div>
<div class=" class-i {{myClass}}class-j"></div>
<div class="class-k {{myClass}} class-l"></div>
<div class=" class-m {{myClass}} class-n {{myClass}}class-o "></div>
<div class=" class-p class-q"></div>
=====================================output=====================================
<div class="hello {{if goodbye true}}">
Hello
</div>
<div
class="hello {{if goodbye true}} {{if goodbye false}} {{if goodbye true}} {{
if goodbye false
}} {{if goodbye true}}"
<div class="a very long list of classes that exceeds {{eighty}} chars with emtpy spaces">hey</div>
<a href="a-very-long-href-from-a-third-party-marketing-platform{{id}}longer-than-eighty-chars">Link</a>
<button
class="uk-padding-remove uk-button uk-button-default uk-button-small uk-width-1-{{intl.locales.length}} {{if (contains locale intl.locale) "uk-button-primary"}}"
>
Hello
test
</button>
=====================================output=====================================
<div
class="a very long list of classes that exceeds {{
eighty
}} chars with emtpy spaces"
>
hey
</div>
<a href="/{{url}}/{{url}}"></a>
<div class="class-a{{myClass}}"></div>
<div class="class-b {{myClass}}"></div>
<div class="{{myClass}}class-c"></div>
<div class="{{myClass}} class-d"></div>
<div class="class-e{{myClass}} class-f"></div>
<div class="class-g{{myClass}}class-h"></div>
<div class="class-i {{myClass}}class-j"></div>
<div class="class-k {{myClass}} class-l"></div>
<div class="class-m {{myClass}} class-n {{myClass}}class-o"></div>
<div class='class-p class-q'></div>
<a
href="a-very-long-href-from-a-third-party-marketing-platform{{
id
}}longer-than-eighty-chars"
>
Link
</a>
<button
class="uk-padding-remove uk-button uk-button-default uk-button-small uk-width-1-{{
intl.locales.length
}} {{if (contains locale intl.locale) 'uk-button-primary'}}"
>
test
</button>
================================================================================
`;
@@ -147,43 +187,3 @@ printWidth: 80
</button>
================================================================================
`;
exports[`in-attr-node.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div class="a very long list of classes that exceeds {{eighty}} chars with emtpy spaces">hey</div>
<a href="a-very-long-href-from-a-third-party-marketing-platform{{id}}longer-than-eighty-chars">Link</a>
<button
class="uk-padding-remove uk-button uk-button-default uk-button-small uk-width-1-{{intl.locales.length}} {{if (contains locale intl.locale) "uk-button-primary"}}"
>
test
</button>
=====================================output=====================================
<div
class="a very long list of classes that exceeds {{
eighty
}} chars with emtpy spaces"
>
hey
</div>
<a
href="a-very-long-href-from-a-third-party-marketing-platform{{
id
}}longer-than-eighty-chars"
>
Link
</a>
<button
class="uk-padding-remove uk-button uk-button-default uk-button-small uk-width-1-{{
intl.locales.length
}} {{if (contains locale intl.locale) 'uk-button-primary'}}"
>
test
</button>
================================================================================
`;
@@ -1,5 +1,89 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`element-node.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div class="attribute" {{modifier}} {{! comment}}>
Hello
</div>
<div>
Hello
</div>
<div>
hi
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more and more.
</div>
<div>
{{#block}}
{{hello}}
{{/block}}
</div>
<div>
{{hello}}
</div>
<div></div>
<img />
=====================================output=====================================
<div class='attribute' {{modifier}} {{! comment}}>
Hello
</div>
<div>
Hello
</div>
<div>
hi
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more and more.
</div>
<div>
{{#block}}
{{hello}}
{{/block}}
</div>
<div>
{{hello}}
</div>
<div></div>
<img />
================================================================================
`;
exports[`element-node.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -82,87 +166,3 @@ printWidth: 80
<img />
================================================================================
`;
exports[`element-node.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div class="attribute" {{modifier}} {{! comment}}>
Hello
</div>
<div>
Hello
</div>
<div>
hi
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more and more.
</div>
<div>
{{#block}}
{{hello}}
{{/block}}
</div>
<div>
{{hello}}
</div>
<div></div>
<img />
=====================================output=====================================
<div class='attribute' {{modifier}} {{! comment}}>
Hello
</div>
<div>
Hello
</div>
<div>
hi
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more.
</div>
<div>
A long enough string to trigger a line break that would prevent wrapping more and more.
</div>
<div>
{{#block}}
{{hello}}
{{/block}}
</div>
<div>
{{hello}}
</div>
<div></div>
<img />
================================================================================
`;
@@ -1,5 +1,20 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`html-entities.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<p>Some escaped characters: &lt; &gt; &amp;</p>
=====================================output=====================================
<p>
Some escaped characters: &lt; &gt; &amp;
</p>
================================================================================
`;
exports[`html-entities.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -13,18 +28,3 @@ printWidth: 80
</p>
================================================================================
`;
exports[`html-entities.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<p>Some escaped characters: &lt; &gt; &amp;</p>
=====================================output=====================================
<p>
Some escaped characters: &lt; &gt; &amp;
</p>
================================================================================
`;
@@ -1,5 +1,18 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`empty-with-no-trailing-newline.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
=====================================output=====================================
================================================================================
`;
exports[`empty-with-no-trailing-newline.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -12,7 +25,7 @@ printWidth: 80
================================================================================
`;
exports[`empty-with-no-trailing-newline.hbs format 2`] = `
exports[`empty-with-trailing-newline.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
@@ -20,6 +33,7 @@ singleQuote: true
| printWidth
=====================================input======================================
=====================================output=====================================
================================================================================
@@ -38,17 +52,17 @@ printWidth: 80
================================================================================
`;
exports[`empty-with-trailing-newline.hbs format 2`] = `
exports[`end-of-line-last.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
a bare string to hightlight eol last handling
=====================================output=====================================
a bare string to hightlight eol last handling
================================================================================
`;
@@ -64,17 +78,3 @@ a bare string to hightlight eol last handling
a bare string to hightlight eol last handling
================================================================================
`;
exports[`end-of-line-last.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
a bare string to hightlight eol last handling
=====================================output=====================================
a bare string to hightlight eol last handling
================================================================================
`;
@@ -1,5 +1,124 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`basics.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<GlimmerComponent @progress={{aPropertyEngdingAfterEightiethColumnToHighlightAWeirdClosingParenIssue}}
/>
<GlimmerComponent
class="medium"
@autocomplete="off"
@errors={{or this.aLongProperty (and this.aProperty (v-get bike "number" "message"))}}
data-test-beneficiary-account-number
/>
<GlimmerComponent
class="medium"
@autocomplete="off"
@errors={{or this.aVeryLongProperty (and this.aProperty (v-get bike "number" "message"))}}
data-test-beneficiary-account-number
/>
<div class="a long list of classes more than 80 chars with a complex mustache statement {{if (or this.a this.b) this.c this.d}}">
</div>
<div class="a multi line list of classes with a complex mustache statement
{{if (or this.a this.b) this.c this.d}}">
</div>
<div class="a-first-class {{if this.optionOne "optionOne"}} {{if this.optionTwo "optionTwo"}} {{if this.optionThree "optionThree"}} {{if this.optionFour "optionFour"}} {{if this.optionFive "optionFive"}} {{this.class}}" ...attributes >
</div>
<div
class="a-first-class
{{if this.optionOne "optionOne"}}
{{if this.optionTwo "optionTwo"}}
{{if this.optionThree "optionThree"}}
{{if this.optionFour "optionFour"}}
{{if this.optionFive "optionFive"}}
{{this.class}}"
...attributes >
</div>
=====================================output=====================================
<GlimmerComponent
@progress={{
aPropertyEngdingAfterEightiethColumnToHighlightAWeirdClosingParenIssue
}}
/>
<GlimmerComponent
class='medium'
@autocomplete='off'
@errors={{
or this.aLongProperty (and this.aProperty (v-get bike 'number' 'message'))
}}
data-test-beneficiary-account-number
/>
<GlimmerComponent
class='medium'
@autocomplete='off'
@errors={{
or
this.aVeryLongProperty
(and this.aProperty (v-get bike 'number' 'message'))
}}
data-test-beneficiary-account-number
/>
<div
class="a long list of classes more than 80 chars with a complex mustache statement {{
if (or this.a this.b) this.c this.d
}}"
>
</div>
<div
class="a multi line list of classes with a complex mustache statement
{{if (or this.a this.b) this.c this.d}}"
>
</div>
<div
class="a-first-class {{if this.optionOne 'optionOne'}} {{
if this.optionTwo 'optionTwo'
}} {{if this.optionThree 'optionThree'}} {{
if this.optionFour 'optionFour'
}} {{if this.optionFive 'optionFive'}} {{this.class}}"
...attributes
>
</div>
<div
class="a-first-class
{{if this.optionOne 'optionOne'}}
{{if this.optionTwo 'optionTwo'}}
{{if this.optionThree 'optionThree'}}
{{if this.optionFour 'optionFour'}}
{{if this.optionFive 'optionFive'}}
{{this.class}}"
...attributes
>
</div>
================================================================================
`;
exports[`basics.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -118,121 +237,79 @@ printWidth: 80
================================================================================
`;
exports[`basics.hbs format 2`] = `
exports[`element-modifier-statement.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<GlimmerComponent @progress={{aPropertyEngdingAfterEightiethColumnToHighlightAWeirdClosingParenIssue}}
/>
<GlimmerComponent
class="medium"
@autocomplete="off"
@errors={{or this.aLongProperty (and this.aProperty (v-get bike "number" "message"))}}
data-test-beneficiary-account-number
/>
<GlimmerComponent
class="medium"
@autocomplete="off"
@errors={{or this.aVeryLongProperty (and this.aProperty (v-get bike "number" "message"))}}
data-test-beneficiary-account-number
/>
<div class="a long list of classes more than 80 chars with a complex mustache statement {{if (or this.a this.b) this.c this.d}}">
<div {{hello param hash=key}} {{goodbye param}}>
Hello
</div>
<div class="a multi line list of classes with a complex mustache statement
{{if (or this.a this.b) this.c this.d}}">
<div {{hello param param param param param param param param param param param param}}>
Hello
</div>
<div class="a-first-class {{if this.optionOne "optionOne"}} {{if this.optionTwo "optionTwo"}} {{if this.optionThree "optionThree"}} {{if this.optionFour "optionFour"}} {{if this.optionFive "optionFive"}} {{this.class}}" ...attributes >
<div {{hello hashPair=value hashPair=value hashPair=value hashPair=value hashPair=value}}>
Hello
</div>
<div
class="a-first-class
{{if this.optionOne "optionOne"}}
{{if this.optionTwo "optionTwo"}}
{{if this.optionThree "optionThree"}}
{{if this.optionFour "optionFour"}}
{{if this.optionFive "optionFive"}}
{{this.class}}"
...attributes >
<div {{hello param param param param hashPair=value hashPair=value hashPair=value hashPair=value hashPair=value}}>
Hello
</div>
=====================================output=====================================
<GlimmerComponent
@progress={{
aPropertyEngdingAfterEightiethColumnToHighlightAWeirdClosingParenIssue
}}
/>
<GlimmerComponent
class='medium'
@autocomplete='off'
@errors={{
or this.aLongProperty (and this.aProperty (v-get bike 'number' 'message'))
}}
data-test-beneficiary-account-number
/>
<GlimmerComponent
class='medium'
@autocomplete='off'
@errors={{
or
this.aVeryLongProperty
(and this.aProperty (v-get bike 'number' 'message'))
}}
data-test-beneficiary-account-number
/>
<div
class="a long list of classes more than 80 chars with a complex mustache statement {{
if (or this.a this.b) this.c this.d
}}"
>
<div {{hello param hash=key}} {{goodbye param}}>
Hello
</div>
<div
class="a multi line list of classes with a complex mustache statement
{{if (or this.a this.b) this.c this.d}}"
{{hello
param
param
param
param
param
param
param
param
param
param
param
param
}}
>
Hello
</div>
<div
class="a-first-class {{if this.optionOne 'optionOne'}} {{
if this.optionTwo 'optionTwo'
}} {{if this.optionThree 'optionThree'}} {{
if this.optionFour 'optionFour'
}} {{if this.optionFive 'optionFive'}} {{this.class}}"
...attributes
{{hello
hashPair=value
hashPair=value
hashPair=value
hashPair=value
hashPair=value
}}
>
Hello
</div>
<div
class="a-first-class
{{if this.optionOne 'optionOne'}}
{{if this.optionTwo 'optionTwo'}}
{{if this.optionThree 'optionThree'}}
{{if this.optionFour 'optionFour'}}
{{if this.optionFive 'optionFive'}}
{{this.class}}"
...attributes
{{hello
param
param
param
param
hashPair=value
hashPair=value
hashPair=value
hashPair=value
hashPair=value
}}
>
Hello
</div>
================================================================================
`;
@@ -312,80 +389,3 @@ printWidth: 80
</div>
================================================================================
`;
exports[`element-modifier-statement.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div {{hello param hash=key}} {{goodbye param}}>
Hello
</div>
<div {{hello param param param param param param param param param param param param}}>
Hello
</div>
<div {{hello hashPair=value hashPair=value hashPair=value hashPair=value hashPair=value}}>
Hello
</div>
<div {{hello param param param param hashPair=value hashPair=value hashPair=value hashPair=value hashPair=value}}>
Hello
</div>
=====================================output=====================================
<div {{hello param hash=key}} {{goodbye param}}>
Hello
</div>
<div
{{hello
param
param
param
param
param
param
param
param
param
param
param
param
}}
>
Hello
</div>
<div
{{hello
hashPair=value
hashPair=value
hashPair=value
hashPair=value
hashPair=value
}}
>
Hello
</div>
<div
{{hello
param
param
param
param
hashPair=value
hashPair=value
hashPair=value
hashPair=value
hashPair=value
}}
>
Hello
</div>
================================================================================
`;
@@ -1,5 +1,82 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`prettier-ignore.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
{{! prettier-ignore }}
<div>
"hello! my parent was ignored"
{{#my-crazy-component "shall" be="preserved"}}
<This
is="preserved"
/>
{{/my-crazy-component}}
</div>
{{#a-normal-component isRestoredTo = "order" }}
<ThisWillBeNormal backTo = "normal" />
{{/a-normal-component}}
<div class="this should be fixed" >
<Sibling isFixed = {{true}} />
{{! prettier-ignore }}
<div class = " left in chaos as well as children " >
<SomeComponent @broken = {{ true }}></SomeComponent>
</div>
{{#another-sibling as |isFixed|}}
<div class = "fixed" >{{ isFixed }}
All of this should be fixed
</div>
{{/another-sibling}}
</div>
=====================================output=====================================
{{! prettier-ignore }}
<div>
"hello! my parent was ignored"
{{#my-crazy-component "shall" be="preserved"}}
<This
is="preserved"
/>
{{/my-crazy-component}}
</div>
{{#a-normal-component isRestoredTo='order'}}
<ThisWillBeNormal backTo='normal' />
{{/a-normal-component}}
<div class='this should be fixed'>
<Sibling isFixed={{true}} />
{{! prettier-ignore }}
<div class = " left in chaos as well as children " >
<SomeComponent @broken = {{ true }}></SomeComponent>
</div>
{{#another-sibling as |isFixed|}}
<div class='fixed'>
{{isFixed}}
All of this should be fixed
</div>
{{/another-sibling}}
</div>
================================================================================
`;
exports[`prettier-ignore.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -75,80 +152,3 @@ printWidth: 80
</div>
================================================================================
`;
exports[`prettier-ignore.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
{{! prettier-ignore }}
<div>
"hello! my parent was ignored"
{{#my-crazy-component "shall" be="preserved"}}
<This
is="preserved"
/>
{{/my-crazy-component}}
</div>
{{#a-normal-component isRestoredTo = "order" }}
<ThisWillBeNormal backTo = "normal" />
{{/a-normal-component}}
<div class="this should be fixed" >
<Sibling isFixed = {{true}} />
{{! prettier-ignore }}
<div class = " left in chaos as well as children " >
<SomeComponent @broken = {{ true }}></SomeComponent>
</div>
{{#another-sibling as |isFixed|}}
<div class = "fixed" >{{ isFixed }}
All of this should be fixed
</div>
{{/another-sibling}}
</div>
=====================================output=====================================
{{! prettier-ignore }}
<div>
"hello! my parent was ignored"
{{#my-crazy-component "shall" be="preserved"}}
<This
is="preserved"
/>
{{/my-crazy-component}}
</div>
{{#a-normal-component isRestoredTo='order'}}
<ThisWillBeNormal backTo='normal' />
{{/a-normal-component}}
<div class='this should be fixed'>
<Sibling isFixed={{true}} />
{{! prettier-ignore }}
<div class = " left in chaos as well as children " >
<SomeComponent @broken = {{ true }}></SomeComponent>
</div>
{{#another-sibling as |isFixed|}}
<div class='fixed'>
{{isFixed}}
All of this should be fixed
</div>
{{/another-sibling}}
</div>
================================================================================
`;
@@ -1,5 +1,104 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`sub-expressions.hbs - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div
{{mustache
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper param param param param hashPair=value hashPair=value hashPair=Value)
hashPair=(helper param param param param param param hashPair=value hashPair=value hashPair=value)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}
></div>
{{#block
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper param param param param hashPair=value hashPair=value hashPair=Value)
hashPair=(helper param param param param param param hashPair=value hashPair=value hashPair=value)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}
{{/block}}
{{foobar-sub-component/foobar-foo
hook="stringLiteral"
foo=
(t
(concat "stringLiteral" (get blockParam "stringLiteral") hash=hash hash=hash)
foo=(simple-helper (hash hashKey=blockParam.foo assignParam=blockParam.bar))
)
}}
=====================================output=====================================
<div
{{mustache
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper
param param param param hashPair=value hashPair=value hashPair=Value
)
hashPair=(helper
param
param
param
param
param
param
hashPair=value
hashPair=value
hashPair=value
)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}
></div>
{{#block
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper
param param param param hashPair=value hashPair=value hashPair=Value
)
hashPair=(helper
param
param
param
param
param
param
hashPair=value
hashPair=value
hashPair=value
)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}{{/block}}
{{foobar-sub-component/foobar-foo
hook='stringLiteral'
foo=(t
(concat
'stringLiteral' (get blockParam 'stringLiteral') hash=hash hash=hash
)
foo=(simple-helper (hash hashKey=blockParam.foo assignParam=blockParam.bar))
)
}}
================================================================================
`;
exports[`sub-expressions.hbs format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
@@ -97,102 +196,3 @@ printWidth: 80
}}
================================================================================
`;
exports[`sub-expressions.hbs format 2`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<div
{{mustache
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper param param param param hashPair=value hashPair=value hashPair=Value)
hashPair=(helper param param param param param param hashPair=value hashPair=value hashPair=value)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}
></div>
{{#block
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper param param param param hashPair=value hashPair=value hashPair=Value)
hashPair=(helper param param param param param param hashPair=value hashPair=value hashPair=value)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}
{{/block}}
{{foobar-sub-component/foobar-foo
hook="stringLiteral"
foo=
(t
(concat "stringLiteral" (get blockParam "stringLiteral") hash=hash hash=hash)
foo=(simple-helper (hash hashKey=blockParam.foo assignParam=blockParam.bar))
)
}}
=====================================output=====================================
<div
{{mustache
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper
param param param param hashPair=value hashPair=value hashPair=Value
)
hashPair=(helper
param
param
param
param
param
param
hashPair=value
hashPair=value
hashPair=value
)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}
></div>
{{#block
(concat
(service)
(helper param hashPair=Value)
(largeNameHelper
param param param param hashPair=value hashPair=value hashPair=Value
)
hashPair=(helper
param
param
param
param
param
param
hashPair=value
hashPair=value
hashPair=value
)
hashPair=(does not need a line break due to being under 80 chars long)
)
}}{{/block}}
{{foobar-sub-component/foobar-foo
hook='stringLiteral'
foo=(t
(concat
'stringLiteral' (get blockParam 'stringLiteral') hash=hash hash=hash
)
foo=(simple-helper (hash hashKey=blockParam.foo assignParam=blockParam.bar))
)
}}
================================================================================
`;
@@ -1,5 +1,46 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`template.html - {"singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["html"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<script id="entry-template" type="text/x-handlebars-template">
<div class="entry">
<h1>{{title}}</h1>
<div class="body">{{body}}</div></div>
</script>
<script type="text/x-handlebars-template">
{{component arg1='hey' arg2=(helper this.arg7 this.arg4) arg3=anotherone arg6=this.arg8}}
</script>
=====================================output=====================================
<script id="entry-template" type="text/x-handlebars-template">
<div class='entry'>
<h1>
{{title}}
</h1>
<div class='body'>
{{body}}
</div>
</div>
</script>
<script type="text/x-handlebars-template">
{{component
arg1='hey'
arg2=(helper this.arg7 this.arg4)
arg3=anotherone
arg6=this.arg8
}}
</script>
================================================================================
`;
exports[`template.html format 1`] = `
====================================options=====================================
parsers: ["html"]
@@ -39,44 +80,3 @@ printWidth: 80
================================================================================
`;
exports[`template.html format 2`] = `
====================================options=====================================
parsers: ["html"]
printWidth: 80
singleQuote: true
| printWidth
=====================================input======================================
<script id="entry-template" type="text/x-handlebars-template">
<div class="entry">
<h1>{{title}}</h1>
<div class="body">{{body}}</div></div>
</script>
<script type="text/x-handlebars-template">
{{component arg1='hey' arg2=(helper this.arg7 this.arg4) arg3=anotherone arg6=this.arg8}}
</script>
=====================================output=====================================
<script id="entry-template" type="text/x-handlebars-template">
<div class='entry'>
<h1>
{{title}}
</h1>
<div class='body'>
{{body}}
</div>
</div>
</script>
<script type="text/x-handlebars-template">
{{component
arg1='hey'
arg2=(helper this.arg7 this.arg4)
arg3=anotherone
arg6=this.arg8
}}
</script>
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`basics.hbs format 1`] = `
exports[`basics.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -94,7 +94,7 @@ printWidth: 40
================================================================================
`;
exports[`boss.hbs format 1`] = `
exports[`boss.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -145,7 +145,7 @@ hey
================================================================================
`;
exports[`curly.hbs format 1`] = `
exports[`curly.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -163,7 +163,7 @@ printWidth: 40
================================================================================
`;
exports[`display-inline-block.hbs format 1`] = `
exports[`display-inline-block.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -209,7 +209,7 @@ Click here! Click here! Click here! Click here! Click here! Click here!
================================================================================
`;
exports[`display-none.hbs format 1`] = `
exports[`display-none.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -233,7 +233,7 @@ printWidth: 40
================================================================================
`;
exports[`fill.hbs format 1`] = `
exports[`fill.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -270,7 +270,7 @@ printWidth: 40
================================================================================
`;
exports[`inline-element.hbs format 1`] = `
exports[`inline-element.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -327,7 +327,7 @@ conubia nostra, per inceptos himenaeos. Donec in ornare velit.
================================================================================
`;
exports[`non-breaking-whitespace.hbs format 1`] = `
exports[`non-breaking-whitespace.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -356,7 +356,7 @@ printWidth: 40
================================================================================
`;
exports[`preserved-spaces-and-breaks.hbs format 1`] = `
exports[`preserved-spaces-and-breaks.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -448,7 +448,7 @@ sometimes{{nogaps
================================================================================
`;
exports[`punctuation.hbs format 1`] = `
exports[`punctuation.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -471,7 +471,7 @@ printWidth: 40
================================================================================
`;
exports[`surrounding-linebreak.hbs format 1`] = `
exports[`surrounding-linebreak.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -524,7 +524,7 @@ printWidth: 40
================================================================================
`;
exports[`table.hbs format 1`] = `
exports[`table.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
@@ -611,7 +611,7 @@ printWidth: 40
================================================================================
`;
exports[`whitespace-control.hbs format 1`] = `
exports[`whitespace-control.hbs - {"printWidth":40} format 1`] = `
====================================options=====================================
parsers: ["glimmer"]
printWidth: 40
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
+41 -41
View File
@@ -1,6 +1,45 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`attributes.html format 1`] = `
exports[`attributes.html - {"parser":"lwc","semi":false} format 1`] = `
====================================options=====================================
parser: "lwc"
parsers: ["lwc"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
<template>
<div
data-for={value}
data-for={value[0]}
data-for={value.toString()}
data-for={value()}
class="test"
></div>
</template>
<template if:true={value.error}>
<c-error-panel errors={value.error}></c-error-panel>
</template>
<a href="#" onclick={aFunction}>
=====================================output=====================================
<template>
<div
data-for={value}
data-for={value[0]}
data-for={value.toString()}
data-for={value()}
class="test"
></div>
</template>
<template if:true={value.error}>
<c-error-panel errors={value.error}></c-error-panel>
</template>
<a href="#" onclick={aFunction}></a>
================================================================================
`;
exports[`attributes.html - {"parser":"lwc","trailingComma":"none"} format 1`] = `
====================================options=====================================
parser: "lwc"
parsers: ["lwc"]
@@ -39,7 +78,7 @@ trailingComma: "none"
================================================================================
`;
exports[`attributes.html format 2`] = `
exports[`attributes.html - {"parser":"lwc"} format 1`] = `
====================================options=====================================
parser: "lwc"
parsers: ["lwc"]
@@ -76,42 +115,3 @@ printWidth: 80
================================================================================
`;
exports[`attributes.html format 3`] = `
====================================options=====================================
parser: "lwc"
parsers: ["lwc"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
<template>
<div
data-for={value}
data-for={value[0]}
data-for={value.toString()}
data-for={value()}
class="test"
></div>
</template>
<template if:true={value.error}>
<c-error-panel errors={value.error}></c-error-panel>
</template>
<a href="#" onclick={aFunction}>
=====================================output=====================================
<template>
<div
data-for={value}
data-for={value[0]}
data-for={value.toString()}
data-for={value()}
class="test"
></div>
</template>
<template if:true={value.error}>
<c-error-panel errors={value.error}></c-error-panel>
</template>
<a href="#" onclick={aFunction}></a>
================================================================================
`;
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -1,63 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`inside-template.vue format 1`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
vueIndentScriptAndStyle: true
| printWidth
=====================================input======================================
<template>
<style>
br {
background: #00abc9;
}
div {
background: #00abc9;
}
</style>
<script>
console.log('hello');
console.log('hello');
</script>
<br />
<footer>
foo
<br/>
</footer>
</template>
=====================================output=====================================
<template>
<style>
br {
background: #00abc9;
}
div {
background: #00abc9;
}
</style>
<script>
console.log("hello");
console.log("hello");
</script>
<br />
<footer>
foo
<br />
</footer>
</template>
================================================================================
`;
exports[`inside-template.vue format 2`] = `
exports[`inside-template.vue - {"vueIndentScriptAndStyle":false} format 1`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
@@ -114,53 +57,53 @@ vueIndentScriptAndStyle: false
================================================================================
`;
exports[`vue-tag-indent.vue format 1`] = `
exports[`inside-template.vue - {"vueIndentScriptAndStyle":true} format 1`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
vueIndentScriptAndStyle: true
| printWidth
=====================================input======================================
<script>
console.log('hello');
console.log('hello');
</script>
<style lang="scss">
footer {
background: #00abc9;
}
footer {
background: #00abc9;
}
</style>
<template>
<br />
<footer>
foo
<br/>
</footer>
<style>
br {
background: #00abc9;
}
div {
background: #00abc9;
}
</style>
<script>
console.log('hello');
console.log('hello');
</script>
<br />
<footer>
foo
<br/>
</footer>
</template>
=====================================output=====================================
<script>
console.log("hello");
console.log("hello");
</script>
<style lang="scss">
footer {
background: #00abc9;
}
footer {
background: #00abc9;
}
</style>
<template>
<style>
br {
background: #00abc9;
}
div {
background: #00abc9;
}
</style>
<script>
console.log("hello");
console.log("hello");
</script>
<br />
<footer>
foo
@@ -171,7 +114,7 @@ footer {
================================================================================
`;
exports[`vue-tag-indent.vue format 2`] = `
exports[`vue-tag-indent.vue - {"vueIndentScriptAndStyle":false} format 1`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
@@ -227,3 +170,60 @@ footer {
================================================================================
`;
exports[`vue-tag-indent.vue - {"vueIndentScriptAndStyle":true} format 1`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
vueIndentScriptAndStyle: true
| printWidth
=====================================input======================================
<script>
console.log('hello');
console.log('hello');
</script>
<style lang="scss">
footer {
background: #00abc9;
}
footer {
background: #00abc9;
}
</style>
<template>
<br />
<footer>
foo
<br/>
</footer>
</template>
=====================================output=====================================
<script>
console.log("hello");
console.log("hello");
</script>
<style lang="scss">
footer {
background: #00abc9;
}
footer {
background: #00abc9;
}
</style>
<template>
<br />
<footer>
foo
<br />
</footer>
</template>
================================================================================
`;
+149 -149
View File
@@ -1,5 +1,40 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`brackets.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns
} from '.';
import {fitsIn, oneLine} from '.';
=====================================output=====================================
import {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns,
} from ".";
import {fitsIn, oneLine} from ".";
================================================================================
`;
exports[`brackets.js format 1`] = `
====================================options=====================================
parsers: ["flow", "typescript"]
@@ -34,37 +69,107 @@ import { fitsIn, oneLine } from ".";
================================================================================
`;
exports[`brackets.js format 2`] = `
exports[`comments.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import { a //comment1
//comment2
//comment3
as b} from "";
import {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns
} from '.';
import {fitsIn, oneLine} from '.';
a as //comment1
//comment2
//comment3
b1
} from "";
import {
a as //comment2 //comment1
//comment3
b2
} from "";
import {
a as //comment3 //comment2 //comment1
b3
} from "";
import {
// comment 1
FN1, // comment 2
/* comment 3 */ FN2,
// FN3,
FN4 /* comment 4 */
// FN4,
// FN5
} from "./module";
import {
ExecutionResult,
DocumentNode,
/* tslint:disable */
SelectionSetNode,
/* tslint:enable */
} from 'graphql';
import x, {
// comment
y
} from 'z';
=====================================output=====================================
import {
runTaskForChanged,
description,
someOtherLabel,
thatMakes,
itGo,
multiLine,
andMore,
soWeCanGetItTo80Columns,
} from ".";
import {fitsIn, oneLine} from ".";
//comment1
//comment2
//comment3
a as b,
} from "";
import {
//comment1
//comment2
//comment3
a as b1,
} from "";
import {
//comment2 //comment1
//comment3
a as b2,
} from "";
import {
//comment3 //comment2 //comment1
a as b3,
} from "";
import {
// comment 1
FN1, // comment 2
/* comment 3 */ FN2,
// FN3,
FN4 /* comment 4 */,
// FN4,
// FN5
} from "./module";
import {
ExecutionResult,
DocumentNode,
/* tslint:disable */
SelectionSetNode,
/* tslint:enable */
} from "graphql";
import x, {
// comment
y,
} from "z";
================================================================================
`;
@@ -173,107 +278,17 @@ import x, {
================================================================================
`;
exports[`comments.js format 2`] = `
exports[`empty-import.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import { a //comment1
//comment2
//comment3
as b} from "";
import {
a as //comment1
//comment2
//comment3
b1
} from "";
import {
a as //comment2 //comment1
//comment3
b2
} from "";
import {
a as //comment3 //comment2 //comment1
b3
} from "";
import {
// comment 1
FN1, // comment 2
/* comment 3 */ FN2,
// FN3,
FN4 /* comment 4 */
// FN4,
// FN5
} from "./module";
import {
ExecutionResult,
DocumentNode,
/* tslint:disable */
SelectionSetNode,
/* tslint:enable */
} from 'graphql';
import x, {
// comment
y
} from 'z';
import { } from '@types/googlemaps';
=====================================output=====================================
import {
//comment1
//comment2
//comment3
a as b,
} from "";
import {
//comment1
//comment2
//comment3
a as b1,
} from "";
import {
//comment2 //comment1
//comment3
a as b2,
} from "";
import {
//comment3 //comment2 //comment1
a as b3,
} from "";
import {
// comment 1
FN1, // comment 2
/* comment 3 */ FN2,
// FN3,
FN4 /* comment 4 */,
// FN4,
// FN5
} from "./module";
import {
ExecutionResult,
DocumentNode,
/* tslint:disable */
SelectionSetNode,
/* tslint:enable */
} from "graphql";
import x, {
// comment
y,
} from "z";
import {} from "@types/googlemaps";
================================================================================
`;
@@ -292,17 +307,28 @@ import {} from "@types/googlemaps";
================================================================================
`;
exports[`empty-import.js format 2`] = `
exports[`inline.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import { } from '@types/googlemaps';
import somethingSuperLongsomethingSuperLong from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
import {somethingSuperLongsomethingSuperLong1} from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
import a, {somethingSuperLongsomethingSuperLong2} from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
import {a2, somethingSuperLongsomethingSuperLong3} from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
=====================================output=====================================
import {} from "@types/googlemaps";
import somethingSuperLongsomethingSuperLong from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
import {somethingSuperLongsomethingSuperLong1} from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
import a, {
somethingSuperLongsomethingSuperLong2,
} from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
import {
a2,
somethingSuperLongsomethingSuperLong3,
} from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
================================================================================
`;
@@ -332,28 +358,17 @@ import {
================================================================================
`;
exports[`inline.js format 2`] = `
exports[`long-line.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import somethingSuperLongsomethingSuperLong from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
import {somethingSuperLongsomethingSuperLong1} from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
import a, {somethingSuperLongsomethingSuperLong2} from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
import {a2, somethingSuperLongsomethingSuperLong3} from 'somethingSuperLongsomethingSuperLongsomethingSuperLong'
import someCoolUtilWithARatherLongName from '../../../../utils/someCoolUtilWithARatherLongName';
=====================================output=====================================
import somethingSuperLongsomethingSuperLong from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
import {somethingSuperLongsomethingSuperLong1} from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
import a, {
somethingSuperLongsomethingSuperLong2,
} from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
import {
a2,
somethingSuperLongsomethingSuperLong3,
} from "somethingSuperLongsomethingSuperLongsomethingSuperLong";
import someCoolUtilWithARatherLongName from "../../../../utils/someCoolUtilWithARatherLongName";
================================================================================
`;
@@ -372,17 +387,17 @@ import someCoolUtilWithARatherLongName from "../../../../utils/someCoolUtilWithA
================================================================================
`;
exports[`long-line.js format 2`] = `
exports[`multiple_standalones.js - {"bracketSpacing":false} format 1`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import someCoolUtilWithARatherLongName from '../../../../utils/someCoolUtilWithARatherLongName';
import a, * as b from 'a';
=====================================output=====================================
import someCoolUtilWithARatherLongName from "../../../../utils/someCoolUtilWithARatherLongName";
import a, * as b from "a";
================================================================================
`;
@@ -400,18 +415,3 @@ import a, * as b from "a";
================================================================================
`;
exports[`multiple_standalones.js format 2`] = `
====================================options=====================================
bracketSpacing: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import a, * as b from 'a';
=====================================output=====================================
import a, * as b from "a";
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`front-matter.css format 1`] = `
exports[`front-matter.css - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["css"]
@@ -27,7 +27,7 @@ something
================================================================================
`;
exports[`simple.css format 1`] = `
exports[`simple.css - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["css"]
@@ -46,7 +46,7 @@ printWidth: 80
================================================================================
`;
exports[`start-with-comment.css format 1`] = `
exports[`start-with-comment.css - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["css"]
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`with-pragma.graphql format 1`] = `
exports[`with-pragma.graphql - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["graphql"]
@@ -21,7 +21,7 @@ query Browse($offset: Int) {
================================================================================
`;
exports[`without-pragma.graphql format 1`] = `
exports[`without-pragma.graphql - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["graphql"]
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`with-pragma.html format 1`] = `
exports[`with-pragma.html - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["html"]
@@ -19,7 +19,7 @@ Hello World
================================================================================
`;
exports[`without-pragma.html format 1`] = `
exports[`without-pragma.html - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["html"]
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`module-with-late-docblock.js format 1`] = `
exports[`module-with-late-docblock.js - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["flow", "babel", "typescript"]
@@ -32,7 +32,7 @@ const fruit = "tomatoes";
================================================================================
`;
exports[`module-with-multiple-same-pragma.js format 1`] = `
exports[`module-with-multiple-same-pragma.js - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["flow", "babel", "typescript"]
@@ -54,7 +54,7 @@ printWidth: 80
================================================================================
`;
exports[`module-with-pragma.js format 1`] = `
exports[`module-with-pragma.js - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["flow", "babel", "typescript"]
@@ -87,7 +87,7 @@ function foo(bar) {
================================================================================
`;
exports[`module-without-docblock.js format 1`] = `
exports[`module-without-docblock.js - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["flow", "babel", "typescript"]
@@ -108,7 +108,7 @@ function foo(bar) {
================================================================================
`;
exports[`module-without-pragma.js format 1`] = `
exports[`module-without-pragma.js - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["flow", "babel", "typescript"]
@@ -140,7 +140,7 @@ function foo(bar) {
================================================================================
`;
exports[`trailing-spaces-first-line.js format 1`] = `
exports[`trailing-spaces-first-line.js - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["flow", "babel", "typescript"]
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`does-nothing.json format 1`] = `
exports[`does-nothing.json - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["json"]
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`with-pragma.json5 format 1`] = `
exports[`with-pragma.json5 - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["json5"]
@@ -19,7 +19,7 @@ printWidth: 80
================================================================================
`;
exports[`without-pragma.json5 format 1`] = `
exports[`without-pragma.json5 - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["json5"]
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`front-matter.md format 1`] = `
exports[`front-matter.md - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["markdown"]
@@ -29,7 +29,7 @@ some content some content some content some content
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["markdown"]
@@ -50,7 +50,7 @@ some content some content some content some content
================================================================================
`;
exports[`start-with-comment.md format 1`] = `
exports[`start-with-comment.md - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["markdown"]
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`with-pragma.vue format 1`] = `
exports[`with-pragma.vue - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["vue"]
@@ -32,7 +32,7 @@ const x = 1;
================================================================================
`;
exports[`without-pragma.vue format 1`] = `
exports[`without-pragma.vue - {"insertPragma":true} format 1`] = `
====================================options=====================================
insertPragma: true
parsers: ["vue"]
File diff suppressed because it is too large. Load diff
@@ -1,5 +1,35 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`block-comment.json - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
{/*comment*/"K":"V"}
=====================================output=====================================
{ /*comment*/ "K": "V" }
================================================================================
`;
exports[`block-comment.json - {"trailingComma":"all"} format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
{/*comment*/"K":"V"}
=====================================output=====================================
{ /*comment*/ K: "V" }
================================================================================
`;
exports[`block-comment.json format 1`] = `
====================================options=====================================
parsers: ["json"]
@@ -16,44 +46,44 @@ printWidth: 80
exports[`block-comment.json format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
{/*comment*/"K":"V"}
=====================================output=====================================
{ /*comment*/ K: "V" }
================================================================================
`;
exports[`bottom-block-comment.json - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
{/*comment*/"K":"V"}
1 /* block-comment */
=====================================output=====================================
{ /*comment*/ "K": "V" }
1 /* block-comment */
================================================================================
`;
exports[`block-comment.json format 3`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
{/*comment*/"K":"V"}
=====================================output=====================================
{ /*comment*/ K: "V" }
================================================================================
`;
exports[`block-comment.json format 4`] = `
exports[`bottom-block-comment.json - {"trailingComma":"all"} format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
{/*comment*/"K":"V"}
1 /* block-comment */
=====================================output=====================================
{ /*comment*/ K: "V" }
1 /* block-comment */
================================================================================
`;
@@ -74,44 +104,44 @@ printWidth: 80
exports[`bottom-block-comment.json format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
1 /* block-comment */
=====================================output=====================================
1 /* block-comment */
================================================================================
`;
exports[`bottom-line-comment.json - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
1 /* block-comment */
1 // line-comment
=====================================output=====================================
1 /* block-comment */
1 // line-comment
================================================================================
`;
exports[`bottom-block-comment.json format 3`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
1 /* block-comment */
=====================================output=====================================
1 /* block-comment */
================================================================================
`;
exports[`bottom-block-comment.json format 4`] = `
exports[`bottom-line-comment.json - {"trailingComma":"all"} format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
1 /* block-comment */
1 // line-comment
=====================================output=====================================
1 /* block-comment */
1 // line-comment
================================================================================
`;
@@ -132,44 +162,56 @@ printWidth: 80
exports[`bottom-line-comment.json format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
1 // line-comment
=====================================output=====================================
1 // line-comment
================================================================================
`;
exports[`line-comment.json - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
1 // line-comment
{
//comment
"K":"V"
}
=====================================output=====================================
1 // line-comment
{
//comment
"K": "V"
}
================================================================================
`;
exports[`bottom-line-comment.json format 3`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
1 // line-comment
=====================================output=====================================
1 // line-comment
================================================================================
`;
exports[`bottom-line-comment.json format 4`] = `
exports[`line-comment.json - {"trailingComma":"all"} format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
1 // line-comment
{
//comment
"K":"V"
}
=====================================output=====================================
1 // line-comment
{
//comment
K: "V",
}
================================================================================
`;
@@ -196,61 +238,57 @@ printWidth: 80
exports[`line-comment.json format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
{
//comment
"K":"V"
}
=====================================output=====================================
{
//comment
K: "V",
}
================================================================================
`;
exports[`top-block-comment.json - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
{
//comment
"K":"V"
/* comment */{
"foo": "bar"
}
=====================================output=====================================
{
//comment
"K": "V"
/* comment */ {
"foo": "bar"
}
================================================================================
`;
exports[`line-comment.json format 3`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
=====================================input======================================
{
//comment
"K":"V"
}
=====================================output=====================================
{
//comment
K: "V",
}
================================================================================
`;
exports[`line-comment.json format 4`] = `
exports[`top-block-comment.json - {"trailingComma":"all"} format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
{
//comment
"K":"V"
/* comment */{
"foo": "bar"
}
=====================================output=====================================
{
//comment
K: "V",
/* comment */ {
foo: "bar",
}
================================================================================
@@ -276,25 +314,6 @@ printWidth: 80
exports[`top-block-comment.json format 2`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
/* comment */{
"foo": "bar"
}
=====================================output=====================================
/* comment */ {
"foo": "bar"
}
================================================================================
`;
exports[`top-block-comment.json format 3`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
@@ -311,19 +330,46 @@ printWidth: 80
================================================================================
`;
exports[`top-block-comment.json format 4`] = `
exports[`top-line-comment.json - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
// comment 1
// comment 2
{
"foo": "bar"
}
=====================================output=====================================
// comment 1
// comment 2
{
"foo": "bar"
}
================================================================================
`;
exports[`top-line-comment.json - {"trailingComma":"all"} format 2`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
/* comment */{
// comment 1
// comment 2
{
"foo": "bar"
}
=====================================output=====================================
/* comment */ {
// comment 1
// comment 2
{
foo: "bar",
}
@@ -354,29 +400,6 @@ printWidth: 80
exports[`top-line-comment.json format 2`] = `
====================================options=====================================
parsers: ["json"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
// comment 1
// comment 2
{
"foo": "bar"
}
=====================================output=====================================
// comment 1
// comment 2
{
"foo": "bar"
}
================================================================================
`;
exports[`top-line-comment.json format 3`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
| printWidth
@@ -396,26 +419,3 @@ printWidth: 80
================================================================================
`;
exports[`top-line-comment.json format 4`] = `
====================================options=====================================
parsers: ["json5"]
printWidth: 80
trailingComma: "all"
| printWidth
=====================================input======================================
// comment 1
// comment 2
{
"foo": "bar"
}
=====================================output=====================================
// comment 1
// comment 2
{
foo: "bar",
}
================================================================================
`;
+60 -60
View File
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`array-iter.js format 1`] = `
exports[`array-iter.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -78,7 +78,7 @@ const TodoList = ({ todos }) => (
================================================================================
`;
exports[`array-iter.js format 2`] = `
exports[`array-iter.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -156,7 +156,7 @@ const TodoList = ({ todos }) => (
================================================================================
`;
exports[`array-iter.js format 3`] = `
exports[`array-iter.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -234,7 +234,7 @@ const TodoList = ({ todos }) => (
================================================================================
`;
exports[`array-iter.js format 4`] = `
exports[`array-iter.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -312,7 +312,7 @@ const TodoList = ({ todos }) => (
================================================================================
`;
exports[`attr-comments.js format 1`] = `
exports[`attr-comments.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -388,7 +388,7 @@ singleQuote: false
================================================================================
`;
exports[`attr-comments.js format 2`] = `
exports[`attr-comments.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -464,7 +464,7 @@ singleQuote: false
================================================================================
`;
exports[`attr-comments.js format 3`] = `
exports[`attr-comments.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -540,7 +540,7 @@ singleQuote: true
================================================================================
`;
exports[`attr-comments.js format 4`] = `
exports[`attr-comments.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -616,7 +616,7 @@ singleQuote: true
================================================================================
`;
exports[`conditional-expression.js format 1`] = `
exports[`conditional-expression.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -915,7 +915,7 @@ foo ? (
================================================================================
`;
exports[`conditional-expression.js format 2`] = `
exports[`conditional-expression.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -1214,7 +1214,7 @@ foo ? (
================================================================================
`;
exports[`conditional-expression.js format 3`] = `
exports[`conditional-expression.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -1513,7 +1513,7 @@ foo ? (
================================================================================
`;
exports[`conditional-expression.js format 4`] = `
exports[`conditional-expression.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -1812,7 +1812,7 @@ foo ? (
================================================================================
`;
exports[`expression.js format 1`] = `
exports[`expression.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -2100,7 +2100,7 @@ singleQuote: false
================================================================================
`;
exports[`expression.js format 2`] = `
exports[`expression.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -2388,7 +2388,7 @@ singleQuote: false
================================================================================
`;
exports[`expression.js format 3`] = `
exports[`expression.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -2676,7 +2676,7 @@ singleQuote: true
================================================================================
`;
exports[`expression.js format 4`] = `
exports[`expression.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -2964,7 +2964,7 @@ singleQuote: true
================================================================================
`;
exports[`flow_fix_me.js format 1`] = `
exports[`flow_fix_me.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -2988,7 +2988,7 @@ const aDiv = (
================================================================================
`;
exports[`flow_fix_me.js format 2`] = `
exports[`flow_fix_me.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3012,7 +3012,7 @@ const aDiv = (
================================================================================
`;
exports[`flow_fix_me.js format 3`] = `
exports[`flow_fix_me.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3036,7 +3036,7 @@ const aDiv = (
================================================================================
`;
exports[`flow_fix_me.js format 4`] = `
exports[`flow_fix_me.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3060,7 +3060,7 @@ const aDiv = (
================================================================================
`;
exports[`html_escape.js format 1`] = `
exports[`html_escape.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3080,7 +3080,7 @@ export default () => <a href="https://foo.bar?q1=foo&q2=bar" />;
================================================================================
`;
exports[`html_escape.js format 2`] = `
exports[`html_escape.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3100,7 +3100,7 @@ export default () => <a href='https://foo.bar?q1=foo&q2=bar' />;
================================================================================
`;
exports[`html_escape.js format 3`] = `
exports[`html_escape.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3120,7 +3120,7 @@ export default () => <a href="https://foo.bar?q1=foo&q2=bar" />;
================================================================================
`;
exports[`html_escape.js format 4`] = `
exports[`html_escape.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3140,7 +3140,7 @@ export default () => <a href='https://foo.bar?q1=foo&q2=bar' />;
================================================================================
`;
exports[`hug.js format 1`] = `
exports[`hug.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3222,7 +3222,7 @@ singleQuote: false
================================================================================
`;
exports[`hug.js format 2`] = `
exports[`hug.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3304,7 +3304,7 @@ singleQuote: false
================================================================================
`;
exports[`hug.js format 3`] = `
exports[`hug.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3386,7 +3386,7 @@ singleQuote: true
================================================================================
`;
exports[`hug.js format 4`] = `
exports[`hug.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3468,7 +3468,7 @@ singleQuote: true
================================================================================
`;
exports[`logical-expression.js format 1`] = `
exports[`logical-expression.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3546,7 +3546,7 @@ singleQuote: false
================================================================================
`;
exports[`logical-expression.js format 2`] = `
exports[`logical-expression.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3624,7 +3624,7 @@ singleQuote: false
================================================================================
`;
exports[`logical-expression.js format 3`] = `
exports[`logical-expression.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3702,7 +3702,7 @@ singleQuote: true
================================================================================
`;
exports[`logical-expression.js format 4`] = `
exports[`logical-expression.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3780,7 +3780,7 @@ singleQuote: true
================================================================================
`;
exports[`object-property.js format 1`] = `
exports[`object-property.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3820,7 +3820,7 @@ const tabs = [
================================================================================
`;
exports[`object-property.js format 2`] = `
exports[`object-property.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3860,7 +3860,7 @@ const tabs = [
================================================================================
`;
exports[`object-property.js format 3`] = `
exports[`object-property.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3900,7 +3900,7 @@ const tabs = [
================================================================================
`;
exports[`object-property.js format 4`] = `
exports[`object-property.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -3940,7 +3940,7 @@ const tabs = [
================================================================================
`;
exports[`open-break.js format 1`] = `
exports[`open-break.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -3984,7 +3984,7 @@ onClick={() => {
================================================================================
`;
exports[`open-break.js format 2`] = `
exports[`open-break.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -4028,7 +4028,7 @@ onClick={() => {
================================================================================
`;
exports[`open-break.js format 3`] = `
exports[`open-break.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -4072,7 +4072,7 @@ onClick={() => {
================================================================================
`;
exports[`open-break.js format 4`] = `
exports[`open-break.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -4116,7 +4116,7 @@ onClick={() => {
================================================================================
`;
exports[`parens.js format 1`] = `
exports[`parens.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -4168,7 +4168,7 @@ new Foo(<Component />);
================================================================================
`;
exports[`parens.js format 2`] = `
exports[`parens.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -4220,7 +4220,7 @@ new Foo(<Component />);
================================================================================
`;
exports[`parens.js format 3`] = `
exports[`parens.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -4272,7 +4272,7 @@ new Foo(<Component />);
================================================================================
`;
exports[`parens.js format 4`] = `
exports[`parens.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -4324,7 +4324,7 @@ new Foo(<Component />);
================================================================================
`;
exports[`quotes.js format 1`] = `
exports[`quotes.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -4414,7 +4414,7 @@ singleQuote: false
================================================================================
`;
exports[`quotes.js format 2`] = `
exports[`quotes.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -4504,7 +4504,7 @@ singleQuote: false
================================================================================
`;
exports[`quotes.js format 3`] = `
exports[`quotes.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -4594,7 +4594,7 @@ singleQuote: true
================================================================================
`;
exports[`quotes.js format 4`] = `
exports[`quotes.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -4684,7 +4684,7 @@ singleQuote: true
================================================================================
`;
exports[`return-statement.js format 1`] = `
exports[`return-statement.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -4798,7 +4798,7 @@ class BreakingClass extends React.component {
================================================================================
`;
exports[`return-statement.js format 2`] = `
exports[`return-statement.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -4912,7 +4912,7 @@ class BreakingClass extends React.component {
================================================================================
`;
exports[`return-statement.js format 3`] = `
exports[`return-statement.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -5026,7 +5026,7 @@ class BreakingClass extends React.component {
================================================================================
`;
exports[`return-statement.js format 4`] = `
exports[`return-statement.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -5140,7 +5140,7 @@ class BreakingClass extends React.component {
================================================================================
`;
exports[`self-closing.js format 1`] = `
exports[`self-closing.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -5158,7 +5158,7 @@ singleQuote: false
================================================================================
`;
exports[`self-closing.js format 2`] = `
exports[`self-closing.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -5176,7 +5176,7 @@ singleQuote: false
================================================================================
`;
exports[`self-closing.js format 3`] = `
exports[`self-closing.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -5194,7 +5194,7 @@ singleQuote: true
================================================================================
`;
exports[`self-closing.js format 4`] = `
exports[`self-closing.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -5212,7 +5212,7 @@ singleQuote: true
================================================================================
`;
exports[`spacing.js format 1`] = `
exports[`spacing.js - {"singleQuote":false,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -5252,7 +5252,7 @@ const Labels = {
================================================================================
`;
exports[`spacing.js format 2`] = `
exports[`spacing.js - {"singleQuote":false,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -5292,7 +5292,7 @@ const Labels = {
================================================================================
`;
exports[`spacing.js format 3`] = `
exports[`spacing.js - {"singleQuote":true,"jsxSingleQuote":false} format 1`] = `
====================================options=====================================
jsxSingleQuote: false
parsers: ["flow", "babel", "typescript"]
@@ -5332,7 +5332,7 @@ const Labels = {
================================================================================
`;
exports[`spacing.js format 4`] = `
exports[`spacing.js - {"singleQuote":true,"jsxSingleQuote":true} format 1`] = `
====================================options=====================================
jsxSingleQuote: true
parsers: ["flow", "babel", "typescript"]
@@ -1,6 +1,39 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`last_line.js format 1`] = `
exports[`last_line.js - {"jsxBracketSameLine":false} format 1`] = `
====================================options=====================================
jsxBracketSameLine: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
<SomeHighlyConfiguredComponent
onEnter={this.onEnter}
onLeave={this.onLeave}
onChange={this.onChange}
initialValue={this.state.initialValue}
ignoreStuff={true}
>
<div>and the children go here</div>
<div>and here too</div>
</SomeHighlyConfiguredComponent>
=====================================output=====================================
<SomeHighlyConfiguredComponent
onEnter={this.onEnter}
onLeave={this.onLeave}
onChange={this.onChange}
initialValue={this.state.initialValue}
ignoreStuff={true}
>
<div>and the children go here</div>
<div>and here too</div>
</SomeHighlyConfiguredComponent>;
================================================================================
`;
exports[`last_line.js - {"jsxBracketSameLine":true} format 1`] = `
====================================options=====================================
jsxBracketSameLine: true
parsers: ["flow", "typescript"]
@@ -32,70 +65,7 @@ printWidth: 80
================================================================================
`;
exports[`last_line.js format 2`] = `
====================================options=====================================
jsxBracketSameLine: false
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
<SomeHighlyConfiguredComponent
onEnter={this.onEnter}
onLeave={this.onLeave}
onChange={this.onChange}
initialValue={this.state.initialValue}
ignoreStuff={true}
>
<div>and the children go here</div>
<div>and here too</div>
</SomeHighlyConfiguredComponent>
=====================================output=====================================
<SomeHighlyConfiguredComponent
onEnter={this.onEnter}
onLeave={this.onLeave}
onChange={this.onChange}
initialValue={this.state.initialValue}
ignoreStuff={true}
>
<div>and the children go here</div>
<div>and here too</div>
</SomeHighlyConfiguredComponent>;
================================================================================
`;
exports[`single_prop_multiline_string.js format 1`] = `
====================================options=====================================
jsxBracketSameLine: true
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
<path d="M4.765 16.829l3.069-2.946 5.813 5.748
11.33-11.232 3.006 3.18-14.36 14.080z" />;
<Component text="Text
with
newlines">Content</Component>;
=====================================output=====================================
<path
d="M4.765 16.829l3.069-2.946 5.813 5.748
11.33-11.232 3.006 3.18-14.36 14.080z"
/>;
<Component
text="Text
with
newlines">
Content
</Component>;
================================================================================
`;
exports[`single_prop_multiline_string.js format 2`] = `
exports[`single_prop_multiline_string.js - {"jsxBracketSameLine":false} format 1`] = `
====================================options=====================================
jsxBracketSameLine: false
parsers: ["flow", "typescript"]
@@ -125,3 +95,33 @@ printWidth: 80
================================================================================
`;
exports[`single_prop_multiline_string.js - {"jsxBracketSameLine":true} format 1`] = `
====================================options=====================================
jsxBracketSameLine: true
parsers: ["flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
<path d="M4.765 16.829l3.069-2.946 5.813 5.748
11.33-11.232 3.006 3.18-14.36 14.080z" />;
<Component text="Text
with
newlines">Content</Component>;
=====================================output=====================================
<path
d="M4.765 16.829l3.069-2.946 5.813 5.748
11.33-11.232 3.006 3.18-14.36 14.080z"
/>;
<Component
text="Text
with
newlines">
Content
</Component>;
================================================================================
`;
File diff suppressed because it is too large. Load diff
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`code.md format 1`] = `
exports[`code.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -43,7 +43,7 @@ proseWrap: "always"
================================================================================
`;
exports[`ignore-code.md format 1`] = `
exports[`ignore-code.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -158,7 +158,7 @@ proseWrap: "always"
================================================================================
`;
exports[`nested.md format 1`] = `
exports[`nested.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -173,7 +173,7 @@ proseWrap: "always"
================================================================================
`;
exports[`paragraph.md format 1`] = `
exports[`paragraph.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -191,7 +191,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`0-indent-js.md format 1`] = `
exports[`0-indent-js.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -56,7 +56,7 @@ proseWrap: "always"
================================================================================
`;
exports[`additional-space.md format 1`] = `
exports[`additional-space.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -115,7 +115,7 @@ proseWrap: "always"
================================================================================
`;
exports[`backtick.md format 1`] = `
exports[`backtick.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -142,7 +142,7 @@ console.log("hello world!");
================================================================================
`;
exports[`format.md format 1`] = `
exports[`format.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -167,7 +167,7 @@ console.log(213);
================================================================================
`;
exports[`indent.md format 1`] = `
exports[`indent.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -226,7 +226,7 @@ proseWrap: "always"
================================================================================
`;
exports[`lang.md format 1`] = `
exports[`lang.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -245,7 +245,7 @@ console.log("hello world");
================================================================================
`;
exports[`leading-trailing-newlines.md format 1`] = `
exports[`leading-trailing-newlines.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -272,7 +272,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -15,7 +15,7 @@ proseWrap: "always"
================================================================================
`;
exports[`space.md format 1`] = `
exports[`space.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -30,7 +30,7 @@ proseWrap: "always"
================================================================================
`;
exports[`title.md format 1`] = `
exports[`title.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`asterisk.md format 1`] = `
exports[`asterisk.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -15,7 +15,7 @@ _123_
================================================================================
`;
exports[`complex.md format 1`] = `
exports[`complex.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -34,7 +34,7 @@ _bug_?
================================================================================
`;
exports[`special.md format 1`] = `
exports[`special.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -109,7 +109,7 @@ proseWrap: "always"
================================================================================
`;
exports[`underscore.md format 1`] = `
exports[`underscore.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`long.md format 1`] = `
exports[`long.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -24,7 +24,7 @@ proseWrap: "always"
================================================================================
`;
exports[`long.md format 2`] = `
exports[`long.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -42,7 +42,7 @@ proseWrap: "never"
================================================================================
`;
exports[`long.md format 3`] = `
exports[`long.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -62,7 +62,7 @@ proseWrap: "preserve"
================================================================================
`;
exports[`multiline.md format 1`] = `
exports[`multiline.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -122,7 +122,7 @@ proseWrap: "always"
================================================================================
`;
exports[`multiline.md format 2`] = `
exports[`multiline.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -181,7 +181,7 @@ proseWrap: "never"
================================================================================
`;
exports[`multiline.md format 3`] = `
exports[`multiline.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -240,7 +240,7 @@ proseWrap: "preserve"
================================================================================
`;
exports[`sibling.md format 1`] = `
exports[`sibling.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -303,7 +303,7 @@ proseWrap: "always"
================================================================================
`;
exports[`sibling.md format 2`] = `
exports[`sibling.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -366,7 +366,7 @@ proseWrap: "never"
================================================================================
`;
exports[`sibling.md format 3`] = `
exports[`sibling.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -429,7 +429,7 @@ proseWrap: "preserve"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -444,7 +444,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 2`] = `
exports[`simple.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -459,7 +459,7 @@ proseWrap: "never"
================================================================================
`;
exports[`simple.md format 3`] = `
exports[`simple.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`atx.md format 1`] = `
exports[`atx.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -19,7 +19,7 @@ proseWrap: "always"
================================================================================
`;
exports[`long-heading.md format 1`] = `
exports[`long-heading.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -34,7 +34,7 @@ proseWrap: "always"
================================================================================
`;
exports[`mixed.md format 1`] = `
exports[`mixed.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -49,7 +49,7 @@ proseWrap: "always"
================================================================================
`;
exports[`setext.md format 1`] = `
exports[`setext.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -70,7 +70,7 @@ h2
================================================================================
`;
exports[`unbreakable.md format 1`] = `
exports[`unbreakable.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`beginning-tag-after-a-list-item.md format 1`] = `
exports[`beginning-tag-after-a-list-item.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -49,7 +49,7 @@ quoted sentence2</p>
================================================================================
`;
exports[`blank-line-between-htmls.md format 1`] = `
exports[`blank-line-between-htmls.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -68,7 +68,7 @@ proseWrap: "always"
================================================================================
`;
exports[`multiline.md format 1`] = `
exports[`multiline.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -127,7 +127,7 @@ proseWrap: "always"
================================================================================
`;
exports[`multiline-with-trailing-space.md format 1`] = `
exports[`multiline-with-trailing-space.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -186,7 +186,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`indented.md format 1`] = `
exports[`indented.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -27,7 +27,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -44,7 +44,7 @@ This is a long long long long long long long long long long long long long long
================================================================================
`;
exports[`top-level-range.md format 1`] = `
exports[`top-level-range.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -15,7 +15,7 @@ proseWrap: "always"
================================================================================
`;
exports[`title.md format 1`] = `
exports[`title.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`collapsed.md format 1`] = `
exports[`collapsed.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -15,7 +15,7 @@ proseWrap: "always"
================================================================================
`;
exports[`full.md format 1`] = `
exports[`full.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -30,7 +30,7 @@ proseWrap: "always"
================================================================================
`;
exports[`full-no-alt.md format 1`] = `
exports[`full-no-alt.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -45,7 +45,7 @@ proseWrap: "always"
================================================================================
`;
exports[`shortcut.md format 1`] = `
exports[`shortcut.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`example.md format 1`] = `
exports[`example.md - {"proseWrap":"always","useTabs":true} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`backtick.md format 1`] = `
exports[`backtick.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -39,7 +39,7 @@ proseWrap: "always"
================================================================================
`;
exports[`cjk.md format 1`] = `
exports[`cjk.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -54,7 +54,7 @@ proseWrap: "always"
================================================================================
`;
exports[`escape.md format 1`] = `
exports[`escape.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -69,7 +69,7 @@ proseWrap: "always"
================================================================================
`;
exports[`long.md format 1`] = `
exports[`long.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -84,7 +84,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,36 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`semi.md format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
semi: true
| printWidth
=====================================input======================================
\`\`\`jsx
<div>foo</div>
\`\`\`
\`\`\`jsx
const a = 1;
<div>foo</div>;
\`\`\`
=====================================output=====================================
\`\`\`jsx
<div>foo</div>
\`\`\`
\`\`\`jsx
const a = 1;
<div>foo</div>;
\`\`\`
================================================================================
`;
exports[`semi.md format 2`] = `
exports[`semi.md - {"semi":false,"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -59,3 +29,33 @@ const a = 1
================================================================================
`;
exports[`semi.md - {"semi":true,"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
semi: true
| printWidth
=====================================input======================================
\`\`\`jsx
<div>foo</div>
\`\`\`
\`\`\`jsx
const a = 1;
<div>foo</div>;
\`\`\`
=====================================output=====================================
\`\`\`jsx
<div>foo</div>
\`\`\`
\`\`\`jsx
const a = 1;
<div>foo</div>;
\`\`\`
================================================================================
`;
@@ -1,29 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`autolink.md format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
<https://www.example.com>
<hello@example.com>
<mailto:hello@example.com>
=====================================output=====================================
<https://www.example.com>
<hello@example.com>
<mailto:hello@example.com>
================================================================================
`;
exports[`autolink.md format 2`] = `
exports[`autolink.md - {"proseWrap":"always","singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -47,22 +24,30 @@ singleQuote: true
================================================================================
`;
exports[`entity.md format 1`] = `
exports[`autolink.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
[Test](http://localhost:8080/test?language=DE&currency=EUR)
<https://www.example.com>
<hello@example.com>
<mailto:hello@example.com>
=====================================output=====================================
[Test](http://localhost:8080/test?language=DE&currency=EUR)
<https://www.example.com>
<hello@example.com>
<mailto:hello@example.com>
================================================================================
`;
exports[`entity.md format 2`] = `
exports[`entity.md - {"proseWrap":"always","singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -78,22 +63,22 @@ singleQuote: true
================================================================================
`;
exports[`long.md format 1`] = `
exports[`entity.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
[podium context](https://github.schibsted.io/finn/podium/tree/master/packages/podium-context)
[Test](http://localhost:8080/test?language=DE&currency=EUR)
=====================================output=====================================
[podium context](https://github.schibsted.io/finn/podium/tree/master/packages/podium-context)
[Test](http://localhost:8080/test?language=DE&currency=EUR)
================================================================================
`;
exports[`long.md format 2`] = `
exports[`long.md - {"proseWrap":"always","singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -109,22 +94,22 @@ singleQuote: true
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`long.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
[hello](#world)
[podium context](https://github.schibsted.io/finn/podium/tree/master/packages/podium-context)
=====================================output=====================================
[hello](#world)
[podium context](https://github.schibsted.io/finn/podium/tree/master/packages/podium-context)
================================================================================
`;
exports[`simple.md format 2`] = `
exports[`simple.md - {"proseWrap":"always","singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -140,74 +125,22 @@ singleQuote: true
================================================================================
`;
exports[`title.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
[hello](#world "title")
[hello](#world 'title')
[hello](#world (title))
[a](https://example.com "\\"")
[a](https://example.com '\\"')
[a](https://example.com (\\"))
[a](https://example.com "\\'")
[a](https://example.com '\\'')
[a](https://example.com (\\'))
[a](https://example.com "\\'")
[a](https://example.com '\\)')
[a](https://example.com (\\)))
<!-- magical incantations -->
[a](https://example.com "\\"')")
[a](https://example.com '"\\')')
[a](https://example.com ("'\\)))
<!-- mis-parsing, \`\\\` are missing: -->
[a](https://example.com "\\\\\\"")
[a](https://example.com '\\\\\\'')
[a](https://example.com (\\\\\\)))
[a](https://example.com "\\\\'")
[a](https://example.com '\\\\"')
[a](https://example.com (\\\\"))
[hello](#world)
=====================================output=====================================
[hello](#world "title") [hello](#world "title") [hello](#world "title")
[a](https://example.com '"') [a](https://example.com '"')
[a](https://example.com '"')
[a](https://example.com "'") [a](https://example.com "'")
[a](https://example.com "'")
[a](https://example.com "'") [a](https://example.com ")")
[a](https://example.com ")")
<!-- magical incantations -->
[a](https://example.com "\\"')") [a](https://example.com "\\"')")
[a](https://example.com "\\"')")
<!-- mis-parsing, \`\\\` are missing: -->
[a](https://example.com '"') [a](https://example.com "'")
[a](https://example.com ")")
[a](https://example.com "'") [a](https://example.com '"')
[a](https://example.com '"')
[hello](#world)
================================================================================
`;
exports[`title.md format 2`] = `
exports[`title.md - {"proseWrap":"always","singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -275,22 +208,74 @@ singleQuote: true
================================================================================
`;
exports[`url.md format 1`] = `
exports[`title.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
https://www.example.com/
[hello](#world "title")
[hello](#world 'title')
[hello](#world (title))
[a](https://example.com "\\"")
[a](https://example.com '\\"')
[a](https://example.com (\\"))
[a](https://example.com "\\'")
[a](https://example.com '\\'')
[a](https://example.com (\\'))
[a](https://example.com "\\'")
[a](https://example.com '\\)')
[a](https://example.com (\\)))
<!-- magical incantations -->
[a](https://example.com "\\"')")
[a](https://example.com '"\\')')
[a](https://example.com ("'\\)))
<!-- mis-parsing, \`\\\` are missing: -->
[a](https://example.com "\\\\\\"")
[a](https://example.com '\\\\\\'')
[a](https://example.com (\\\\\\)))
[a](https://example.com "\\\\'")
[a](https://example.com '\\\\"')
[a](https://example.com (\\\\"))
=====================================output=====================================
https://www.example.com/
[hello](#world "title") [hello](#world "title") [hello](#world "title")
[a](https://example.com '"') [a](https://example.com '"')
[a](https://example.com '"')
[a](https://example.com "'") [a](https://example.com "'")
[a](https://example.com "'")
[a](https://example.com "'") [a](https://example.com ")")
[a](https://example.com ")")
<!-- magical incantations -->
[a](https://example.com "\\"')") [a](https://example.com "\\"')")
[a](https://example.com "\\"')")
<!-- mis-parsing, \`\\\` are missing: -->
[a](https://example.com '"') [a](https://example.com "'")
[a](https://example.com ")")
[a](https://example.com "'") [a](https://example.com '"')
[a](https://example.com '"')
================================================================================
`;
exports[`url.md format 2`] = `
exports[`url.md - {"proseWrap":"always","singleQuote":true} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -305,3 +290,18 @@ https://www.example.com/
================================================================================
`;
exports[`url.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
https://www.example.com/
=====================================output=====================================
https://www.example.com/
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`cjk.md format 1`] = `
exports[`cjk.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -15,7 +15,7 @@ proseWrap: "always"
================================================================================
`;
exports[`cjk.md format 2`] = `
exports[`cjk.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -30,7 +30,7 @@ proseWrap: "never"
================================================================================
`;
exports[`collapsed.md format 1`] = `
exports[`collapsed.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -45,7 +45,7 @@ proseWrap: "always"
================================================================================
`;
exports[`collapsed.md format 2`] = `
exports[`collapsed.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -60,7 +60,7 @@ proseWrap: "never"
================================================================================
`;
exports[`definition.md format 1`] = `
exports[`definition.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -94,7 +94,7 @@ proseWrap: "always"
================================================================================
`;
exports[`definition.md format 2`] = `
exports[`definition.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -122,7 +122,7 @@ proseWrap: "never"
================================================================================
`;
exports[`full.md format 1`] = `
exports[`full.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -137,7 +137,7 @@ proseWrap: "always"
================================================================================
`;
exports[`full.md format 2`] = `
exports[`full.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -152,7 +152,7 @@ proseWrap: "never"
================================================================================
`;
exports[`shortcut.md format 1`] = `
exports[`shortcut.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -167,7 +167,7 @@ proseWrap: "always"
================================================================================
`;
exports[`shortcut.md format 2`] = `
exports[`shortcut.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -182,7 +182,7 @@ proseWrap: "never"
================================================================================
`;
exports[`title.md format 1`] = `
exports[`title.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -245,7 +245,7 @@ https://example.com (\\\\\\))
================================================================================
`;
exports[`title.md format 2`] = `
exports[`title.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,5 +1,41 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`example-1.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
{% include_relative _installations/tarball.md %}
{% cloudinary nice_prefix_-_for_the_filename.jpg %}
# Userscripts <span>[{% img github.svg alt:"View on GitHub" title:"View on GitHub" %}](https://github.com/Charcoal-SE/Userscripts) [Build <span>status loading…</span>](//travis-ci.org/Charcoal-SE/userscripts){: .build}</span>
{% css userscripts %}
{% js userscripts %}
{{ foo
multiline
where does it end }}
=====================================output=====================================
{% include_relative _installations/tarball.md %}
{% cloudinary nice_prefix_-_for_the_filename.jpg %}
# Userscripts <span>[{% img github.svg alt:"View on GitHub" title:"View on GitHub" %}](https://github.com/Charcoal-SE/Userscripts) [Build <span>status loading…</span>](//travis-ci.org/Charcoal-SE/userscripts){: .build}</span>
{% css userscripts %} {% js userscripts %}
{{ foo
multiline
where does it end }}
================================================================================
`;
exports[`example-1.md format 1`] = `
====================================options=====================================
parsers: ["markdown"]
@@ -35,39 +71,3 @@ where does it end }}
================================================================================
`;
exports[`example-1.md format 2`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "always"
| printWidth
=====================================input======================================
{% include_relative _installations/tarball.md %}
{% cloudinary nice_prefix_-_for_the_filename.jpg %}
# Userscripts <span>[{% img github.svg alt:"View on GitHub" title:"View on GitHub" %}](https://github.com/Charcoal-SE/Userscripts) [Build <span>status loading…</span>](//travis-ci.org/Charcoal-SE/userscripts){: .build}</span>
{% css userscripts %}
{% js userscripts %}
{{ foo
multiline
where does it end }}
=====================================output=====================================
{% include_relative _installations/tarball.md %}
{% cloudinary nice_prefix_-_for_the_filename.jpg %}
# Userscripts <span>[{% img github.svg alt:"View on GitHub" title:"View on GitHub" %}](https://github.com/Charcoal-SE/Userscripts) [Build <span>status loading…</span>](//travis-ci.org/Charcoal-SE/userscripts){: .build}</span>
{% css userscripts %} {% js userscripts %}
{{ foo
multiline
where does it end }}
================================================================================
`;
File diff suppressed because it is too large. Load diff
@@ -1,5 +1,43 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`long-table.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "never"
| printWidth
=====================================input======================================
| Property | Description | Type | Default |
| -------- | ----------- | ---- | ------- |
| bordered | Toggles rendering of the border around the list | boolean | false |
| footer | List footer renderer | string\\|ReactNode | - |
| grid | The grid type of list. You can set grid to something like {gutter: 16, column: 4} | object | - |
| header | List header renderer | string\\|ReactNode | - |
| itemLayout | The layout of list, default is \`horizontal\`, If a vertical list is desired, set the itemLayout property to \`vertical\` | string | - |
| rowKey | Item's unique key, could be a string or function that returns a string | string\\|Function(record):string | \`key\` |
| loading | Shows a loading indicator while the contents of the list are being fetched | boolean\\|[object](https://ant.design/components/spin-cn/#API) ([more](https://github.com/ant-design/ant-design/issues/8659)) | false |
| loadMore | Shows a load more content | string\\|ReactNode | - |
| locale | i18n text including empty text | object | emptyText: 'No Data' <br> |
| pagination | Pagination [config](https://ant.design/components/pagination/), hide it by setting it to false | boolean \\| object | false |
| split | Toggles rendering of the split under the list item | boolean | true |
=====================================output=====================================
| Property | Description | Type | Default |
| --- | --- | --- | --- |
| bordered | Toggles rendering of the border around the list | boolean | false |
| footer | List footer renderer | string\\|ReactNode | - |
| grid | The grid type of list. You can set grid to something like {gutter: 16, column: 4} | object | - |
| header | List header renderer | string\\|ReactNode | - |
| itemLayout | The layout of list, default is \`horizontal\`, If a vertical list is desired, set the itemLayout property to \`vertical\` | string | - |
| rowKey | Item's unique key, could be a string or function that returns a string | string\\|Function(record):string | \`key\` |
| loading | Shows a loading indicator while the contents of the list are being fetched | boolean\\|[object](https://ant.design/components/spin-cn/#API) ([more](https://github.com/ant-design/ant-design/issues/8659)) | false |
| loadMore | Shows a load more content | string\\|ReactNode | - |
| locale | i18n text including empty text | object | emptyText: 'No Data' <br> |
| pagination | Pagination [config](https://ant.design/components/pagination/), hide it by setting it to false | boolean \\| object | false |
| split | Toggles rendering of the split under the list item | boolean | true |
================================================================================
`;
exports[`long-table.md format 1`] = `
====================================options=====================================
parsers: ["markdown"]
@@ -36,41 +74,3 @@ printWidth: 80
================================================================================
`;
exports[`long-table.md format 2`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
proseWrap: "never"
| printWidth
=====================================input======================================
| Property | Description | Type | Default |
| -------- | ----------- | ---- | ------- |
| bordered | Toggles rendering of the border around the list | boolean | false |
| footer | List footer renderer | string\\|ReactNode | - |
| grid | The grid type of list. You can set grid to something like {gutter: 16, column: 4} | object | - |
| header | List header renderer | string\\|ReactNode | - |
| itemLayout | The layout of list, default is \`horizontal\`, If a vertical list is desired, set the itemLayout property to \`vertical\` | string | - |
| rowKey | Item's unique key, could be a string or function that returns a string | string\\|Function(record):string | \`key\` |
| loading | Shows a loading indicator while the contents of the list are being fetched | boolean\\|[object](https://ant.design/components/spin-cn/#API) ([more](https://github.com/ant-design/ant-design/issues/8659)) | false |
| loadMore | Shows a load more content | string\\|ReactNode | - |
| locale | i18n text including empty text | object | emptyText: 'No Data' <br> |
| pagination | Pagination [config](https://ant.design/components/pagination/), hide it by setting it to false | boolean \\| object | false |
| split | Toggles rendering of the split under the list item | boolean | true |
=====================================output=====================================
| Property | Description | Type | Default |
| --- | --- | --- | --- |
| bordered | Toggles rendering of the border around the list | boolean | false |
| footer | List footer renderer | string\\|ReactNode | - |
| grid | The grid type of list. You can set grid to something like {gutter: 16, column: 4} | object | - |
| header | List header renderer | string\\|ReactNode | - |
| itemLayout | The layout of list, default is \`horizontal\`, If a vertical list is desired, set the itemLayout property to \`vertical\` | string | - |
| rowKey | Item's unique key, could be a string or function that returns a string | string\\|Function(record):string | \`key\` |
| loading | Shows a loading indicator while the contents of the list are being fetched | boolean\\|[object](https://ant.design/components/spin-cn/#API) ([more](https://github.com/ant-design/ant-design/issues/8659)) | false |
| loadMore | Shows a load more content | string\\|ReactNode | - |
| locale | i18n text including empty text | object | emptyText: 'No Data' <br> |
| pagination | Pagination [config](https://ant.design/components/pagination/), hide it by setting it to false | boolean \\| object | false |
| split | Toggles rendering of the split under the list item | boolean | true |
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`cjk.md format 1`] = `
exports[`cjk.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -52,7 +52,7 @@ This ia an english paragraph with a CJK quote “中文“.
================================================================================
`;
exports[`cjk.md format 2`] = `
exports[`cjk.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -93,7 +93,7 @@ This ia an english paragraph with a CJK quote “中文“.
================================================================================
`;
exports[`cjk.md format 3`] = `
exports[`cjk.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -136,7 +136,7 @@ This ia an english paragraph with a CJK quote “中文“.
================================================================================
`;
exports[`inline-nodes.md format 1`] = `
exports[`inline-nodes.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -153,7 +153,7 @@ outputted code conforms to a consistent style. (See this
================================================================================
`;
exports[`inline-nodes.md format 2`] = `
exports[`inline-nodes.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -168,7 +168,7 @@ It removes all original styling[\\*](#styling-footnote) and ensures that all out
================================================================================
`;
exports[`inline-nodes.md format 3`] = `
exports[`inline-nodes.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -183,7 +183,7 @@ It removes all original styling[\\*](#styling-footnote) and ensures that all out
================================================================================
`;
exports[`lorem.md format 1`] = `
exports[`lorem.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -217,7 +217,7 @@ Eos eos consequatur.
================================================================================
`;
exports[`lorem.md format 2`] = `
exports[`lorem.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -245,7 +245,7 @@ Et quam mollitia velit iste enim exercitationem nemo. Hic dignissimos eos et. Eo
================================================================================
`;
exports[`lorem.md format 3`] = `
exports[`lorem.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -278,7 +278,7 @@ Hic dignissimos eos et. Eos eos consequatur.
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -294,7 +294,7 @@ long paragraph.
================================================================================
`;
exports[`simple.md format 2`] = `
exports[`simple.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -309,7 +309,7 @@ This is a long long long long long long long long long long long long long long
================================================================================
`;
exports[`simple.md format 3`] = `
exports[`simple.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -324,7 +324,7 @@ This is a long long long long long long long long long long long long long long
================================================================================
`;
exports[`special-prefix.md format 1`] = `
exports[`special-prefix.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -385,7 +385,7 @@ aged 29. Oh no, why are we in a numbered list now?
================================================================================
`;
exports[`special-prefix.md format 2`] = `
exports[`special-prefix.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -439,7 +439,7 @@ She grew up in an isolated village in the 19th century and met her father aged 2
================================================================================
`;
exports[`special-prefix.md format 3`] = `
exports[`special-prefix.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -494,7 +494,7 @@ She grew up in an isolated village in the 19th century and met her father aged 2
================================================================================
`;
exports[`whitespace.md format 1`] = `
exports[`whitespace.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -522,7 +522,7 @@ keep these words together
================================================================================
`;
exports[`whitespace.md format 2`] = `
exports[`whitespace.md - {"proseWrap":"never"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -549,7 +549,7 @@ keep these words together keep these words together keep these words together ke
================================================================================
`;
exports[`whitespace.md format 3`] = `
exports[`whitespace.md - {"proseWrap":"preserve"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
File diff suppressed because it is too large. Load diff
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`chinese-japanese.md format 1`] = `
exports[`chinese-japanese.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -38,7 +38,7 @@ proseWrap: "always"
================================================================================
`;
exports[`korean.md format 1`] = `
exports[`korean.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -53,7 +53,7 @@ proseWrap: "always"
================================================================================
`;
exports[`link.md format 1`] = `
exports[`link.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -68,7 +68,7 @@ proseWrap: "always"
================================================================================
`;
exports[`mixed.md format 1`] = `
exports[`mixed.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -92,7 +92,7 @@ English 混合著中文的一段 Paragraph!
================================================================================
`;
exports[`space.md format 1`] = `
exports[`space.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`asterisk.md format 1`] = `
exports[`asterisk.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -15,7 +15,7 @@ proseWrap: "always"
================================================================================
`;
exports[`underscore.md format 1`] = `
exports[`underscore.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`align.md format 1`] = `
exports[`align.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -19,7 +19,7 @@ proseWrap: "always"
================================================================================
`;
exports[`cjk.md format 1`] = `
exports[`cjk.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -38,7 +38,7 @@ proseWrap: "always"
================================================================================
`;
exports[`emoji.md format 1`] = `
exports[`emoji.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -57,7 +57,7 @@ proseWrap: "always"
================================================================================
`;
exports[`empty.md format 1`] = `
exports[`empty.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -78,7 +78,7 @@ Y |
================================================================================
`;
exports[`escape.md format 1`] = `
exports[`escape.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -97,7 +97,7 @@ proseWrap: "always"
================================================================================
`;
exports[`html.md format 1`] = `
exports[`html.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -116,7 +116,7 @@ Default | CLI Override | API Override
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -135,7 +135,7 @@ proseWrap: "always"
================================================================================
`;
exports[`table.md format 1`] = `
exports[`table.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`list.md format 1`] = `
exports[`list.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -18,7 +18,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`empty.md format 1`] = `
exports[`empty.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -17,7 +17,7 @@ proseWrap: "always"
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`escape.md format 1`] = `
exports[`escape.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`complex.md format 1`] = `
exports[`complex.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -25,7 +25,7 @@ proseWrap: "always"
================================================================================
`;
exports[`empty.md format 1`] = `
exports[`empty.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -42,7 +42,7 @@ proseWrap: "always"
================================================================================
`;
exports[`empty-2.md format 1`] = `
exports[`empty-2.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -63,7 +63,7 @@ Content
================================================================================
`;
exports[`simple.md format 1`] = `
exports[`simple.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -82,7 +82,7 @@ hello: world
================================================================================
`;
exports[`simple-2.md format 1`] = `
exports[`simple-2.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -105,7 +105,7 @@ Content
================================================================================
`;
exports[`trailing-spaces.md format 1`] = `
exports[`trailing-spaces.md - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
+292 -292
View File
@@ -1,5 +1,92 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`import-export.mdx - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["mdx"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
import D from 'd'
import {A,B,C} from "hello-world"
import {AAAAAAAAAAAAAAAAAAAAAAAA, BBBBBBBBBBBBBBBBBBBBBB, CCCCCCCCCCCCCCCCCCCCCCC} from 'xyz';
---
import D from 'd'
import {A,B,C} from "hello-world"
import {AAAAAAAAAAAAAAAAAAAAAAAA, BBBBBBBBBBBBBBBBBBBBBB, CCCCCCCCCCCCCCCCCCCCCCC} from 'xyz';
---
export const meta = {
authors: [fred, sue],
layout: Layout
}
export default () =>
<Doc components={{
h1: ui.Heading,
p: ui.Text,
code: ui.Code
}}
/>
---
export const a = 1;
export const b = 1;
=====================================output=====================================
import D from "d"
import { A, B, C } from "hello-world"
import {
AAAAAAAAAAAAAAAAAAAAAAAA,
BBBBBBBBBBBBBBBBBBBBBB,
CCCCCCCCCCCCCCCCCCCCCCC,
} from "xyz"
---
import D from "d"
import { A, B, C } from "hello-world"
import {
AAAAAAAAAAAAAAAAAAAAAAAA,
BBBBBBBBBBBBBBBBBBBBBB,
CCCCCCCCCCCCCCCCCCCCCCC,
} from "xyz"
---
export const meta = {
authors: [fred, sue],
layout: Layout,
}
export default () => (
<Doc
components={{
h1: ui.Heading,
p: ui.Text,
code: ui.Code,
}}
/>
)
---
export const a = 1
export const b = 1
================================================================================
`;
exports[`import-export.mdx format 1`] = `
====================================options=====================================
parsers: ["mdx"]
@@ -86,89 +173,31 @@ export const b = 1;
================================================================================
`;
exports[`import-export.mdx format 2`] = `
exports[`inline-html.mdx - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["mdx"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
import D from 'd'
import {A,B,C} from "hello-world"
import {AAAAAAAAAAAAAAAAAAAAAAAA, BBBBBBBBBBBBBBBBBBBBBB, CCCCCCCCCCCCCCCCCCCCCCC} from 'xyz';
This is an example of a component _being used in some italic markdown with some <Bolded />,
and as you can see_ once you close the italics, it will break incorrectly when prettier formats it.
---
import D from 'd'
import {A,B,C} from "hello-world"
import {AAAAAAAAAAAAAAAAAAAAAAAA, BBBBBBBBBBBBBBBBBBBBBB, CCCCCCCCCCCCCCCCCCCCCCC} from 'xyz';
---
export const meta = {
authors: [fred, sue],
layout: Layout
}
export default () =>
<Doc components={{
h1: ui.Heading,
p: ui.Text,
code: ui.Code
}}
/>
---
export const a = 1;
export const b = 1;
| Column 1 | Column 2 |
| -- | -- |
| **\`Row 1 Code\`** | Some text. |
| **<code>Row 2 Code</code>** | Some text. |
| **<InlineCode>Row 2 Code</InlineCode>** | Some text. |
=====================================output=====================================
import D from "d"
import { A, B, C } from "hello-world"
import {
AAAAAAAAAAAAAAAAAAAAAAAA,
BBBBBBBBBBBBBBBBBBBBBB,
CCCCCCCCCCCCCCCCCCCCCCC,
} from "xyz"
This is an example of a component _being used in some italic markdown with some <Bolded />,
and as you can see_ once you close the italics, it will break incorrectly when prettier formats it.
---
import D from "d"
import { A, B, C } from "hello-world"
import {
AAAAAAAAAAAAAAAAAAAAAAAA,
BBBBBBBBBBBBBBBBBBBBBB,
CCCCCCCCCCCCCCCCCCCCCCC,
} from "xyz"
---
export const meta = {
authors: [fred, sue],
layout: Layout,
}
export default () => (
<Doc
components={{
h1: ui.Heading,
p: ui.Text,
code: ui.Code,
}}
/>
)
---
export const a = 1
export const b = 1
| Column 1 | Column 2 |
| --------------------------------------- | ---------- |
| **\`Row 1 Code\`** | Some text. |
| **<code>Row 2 Code</code>** | Some text. |
| **<InlineCode>Row 2 Code</InlineCode>** | Some text. |
================================================================================
`;
@@ -201,31 +230,91 @@ and as you can see_ once you close the italics, it will break incorrectly when p
================================================================================
`;
exports[`inline-html.mdx format 2`] = `
exports[`jsx.mdx - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["mdx"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
This is an example of a component _being used in some italic markdown with some <Bolded />,
and as you can see_ once you close the italics, it will break incorrectly when prettier formats it.
<Heading hi='there'>Hello, world!
</Heading>
---
<Hello>
test <World /> test
</Hello>123
---
<Hello>
test <World /> test
</Hello>
<Hello>
test <World /> test
</Hello>123
---
<Hello>
test <World /> test
</Hello> 123
<Hello>
test <World /> test
</Hello> 234
---
<>
test <World /> test
</> 123
---
| Column 1 | Column 2 |
| -- | -- |
| **\`Row 1 Code\`** | Some text. |
| **<code>Row 2 Code</code>** | Some text. |
| **<InlineCode>Row 2 Code</InlineCode>** | Some text. |
|---|---|
| Text | <Hello>Text</Hello> |
=====================================output=====================================
This is an example of a component _being used in some italic markdown with some <Bolded />,
and as you can see_ once you close the italics, it will break incorrectly when prettier formats it.
<Heading hi="there">Hello, world!</Heading>
| Column 1 | Column 2 |
| --------------------------------------- | ---------- |
| **\`Row 1 Code\`** | Some text. |
| **<code>Row 2 Code</code>** | Some text. |
| **<InlineCode>Row 2 Code</InlineCode>** | Some text. |
---
<Hello>
test <World /> test
</Hello>
123
---
<Hello>
test <World /> test
</Hello>
<Hello>
test <World /> test
</Hello>123
---
<Hello>
test <World /> test
</Hello> 123
<Hello>
test <World /> test
</Hello> 234
---
<>
test <World /> test
</> 123
---
| Column 1 | Column 2 |
| -------- | ------------------- |
| Text | <Hello>Text</Hello> |
================================================================================
`;
@@ -318,91 +407,31 @@ printWidth: 80
================================================================================
`;
exports[`jsx.mdx format 2`] = `
exports[`jsx-codeblock.mdx - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["mdx"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
<Heading hi='there'>Hello, world!
</Heading>
\`\`\`jsx
<div>foo</div>
\`\`\`
---
<Hello>
test <World /> test
</Hello>123
---
<Hello>
test <World /> test
</Hello>
<Hello>
test <World /> test
</Hello>123
---
<Hello>
test <World /> test
</Hello> 123
<Hello>
test <World /> test
</Hello> 234
---
<>
test <World /> test
</> 123
---
| Column 1 | Column 2 |
|---|---|
| Text | <Hello>Text</Hello> |
\`\`\`jsx
const a = 1;
<div>foo</div>;
\`\`\`
=====================================output=====================================
<Heading hi="there">Hello, world!</Heading>
\`\`\`jsx
<div>foo</div>
\`\`\`
---
<Hello>
test <World /> test
</Hello>
123
---
<Hello>
test <World /> test
</Hello>
<Hello>
test <World /> test
</Hello>123
---
<Hello>
test <World /> test
</Hello> 123
<Hello>
test <World /> test
</Hello> 234
---
<>
test <World /> test
</> 123
---
| Column 1 | Column 2 |
| -------- | ------------------- |
| Text | <Hello>Text</Hello> |
\`\`\`jsx
const a = 1
;<div>foo</div>
\`\`\`
================================================================================
`;
@@ -435,31 +464,58 @@ const a = 1;
================================================================================
`;
exports[`jsx-codeblock.mdx format 2`] = `
exports[`levels.mdx - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["mdx"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
\`\`\`jsx
<div>foo</div>
\`\`\`
import { Foo, Bar } from './Fixture'
# Hello, world!
<Foo bg='red'>
<div style={{ display: 'block'} }>
<Bar >hi </Bar>
{ hello }
{ /* another comment */}
</div>
</Foo>
asdfsdf <strong style={{fontWeight: 'bolder'}}>asdfasdf</strong>
<Foo/>
test
<ul>
<li >item {' '} </li>
<li/>
</ul >
\`\`\`jsx
const a = 1;
<div>foo</div>;
\`\`\`
=====================================output=====================================
\`\`\`jsx
<div>foo</div>
\`\`\`
import { Foo, Bar } from "./Fixture"
\`\`\`jsx
const a = 1
;<div>foo</div>
\`\`\`
# Hello, world!
<Foo bg="red">
<div style={{ display: "block" }}>
<Bar>hi </Bar>
{hello}
{/* another comment */}
</div>
</Foo>
asdfsdf <strong style={{fontWeight: 'bolder'}}>asdfasdf</strong>
<Foo />
test
<ul>
<li>item </li>
<li />
</ul>
================================================================================
`;
@@ -519,58 +575,93 @@ test
================================================================================
`;
exports[`levels.mdx format 2`] = `
exports[`mixed.mdx - {"semi":false} format 1`] = `
====================================options=====================================
parsers: ["mdx"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
import { Foo, Bar } from './Fixture'
import { Baz } from './Fixture'
import { Buz } from './Fixture'
export const foo = {
hi: \`Fudge \${Baz.displayName || 'Baz'}\`,
authors: [
'fred',
'sally'
]
}
# Hello, world!
I'm an awesome paragraph.
<!-- I'm a comment -->
<Foo bg='red'>
<div style={{ display: 'block'} }>
<Bar >hi </Bar>
{ hello }
{ /* another comment */}
</div>
</Foo>
asdfsdf <strong style={{fontWeight: 'bolder'}}>asdfasdf</strong>
\`\`\`
test codeblock
\`\`\`
<Foo/>
test
\`\`\`js
module.exports = 'test'
\`\`\`
<ul>
<li >item {' '} </li>
<li/>
</ul >
\`\`\`sh
npm i -g foo
\`\`\`
| Test | Table |
| :--- | :---- |
| Col1 | Col2 |
export default ({children }) => < div>{ children}</div>
=====================================output=====================================
import { Foo, Bar } from "./Fixture"
import { Baz } from "./Fixture"
import { Buz } from "./Fixture"
export const foo = {
hi: \`Fudge \${Baz.displayName || "Baz"}\`,
authors: ["fred", "sally"],
}
# Hello, world!
I'm an awesome paragraph.
<!-- I'm a comment -->
<Foo bg="red">
<div style={{ display: "block" }}>
<Bar>hi </Bar>
{hello}
{/* another comment */}
</div>
<Bar>hi </Bar>
{hello}
{/* another comment */}
</Foo>
asdfsdf <strong style={{fontWeight: 'bolder'}}>asdfasdf</strong>
\`\`\`
test codeblock
\`\`\`
<Foo />
test
\`\`\`js
module.exports = "test"
\`\`\`
<ul>
<li>item </li>
<li />
</ul>
\`\`\`sh
npm i -g foo
\`\`\`
| Test | Table |
| :--- | :---- |
| Col1 | Col2 |
export default ({ children }) => <div>{children}</div>
================================================================================
`;
@@ -664,94 +755,3 @@ export default ({ children }) => <div>{children}</div>;
================================================================================
`;
exports[`mixed.mdx format 2`] = `
====================================options=====================================
parsers: ["mdx"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
import { Baz } from './Fixture'
import { Buz } from './Fixture'
export const foo = {
hi: \`Fudge \${Baz.displayName || 'Baz'}\`,
authors: [
'fred',
'sally'
]
}
# Hello, world!
I'm an awesome paragraph.
<!-- I'm a comment -->
<Foo bg='red'>
<Bar >hi </Bar>
{ hello }
{ /* another comment */}
</Foo>
\`\`\`
test codeblock
\`\`\`
\`\`\`js
module.exports = 'test'
\`\`\`
\`\`\`sh
npm i -g foo
\`\`\`
| Test | Table |
| :--- | :---- |
| Col1 | Col2 |
export default ({children }) => < div>{ children}</div>
=====================================output=====================================
import { Baz } from "./Fixture"
import { Buz } from "./Fixture"
export const foo = {
hi: \`Fudge \${Baz.displayName || "Baz"}\`,
authors: ["fred", "sally"],
}
# Hello, world!
I'm an awesome paragraph.
<!-- I'm a comment -->
<Foo bg="red">
<Bar>hi </Bar>
{hello}
{/* another comment */}
</Foo>
\`\`\`
test codeblock
\`\`\`
\`\`\`js
module.exports = "test"
\`\`\`
\`\`\`sh
npm i -g foo
\`\`\`
| Test | Table |
| :--- | :---- |
| Col1 | Col2 |
export default ({ children }) => <div>{children}</div>
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`constructor.js format 1`] = `
exports[`constructor.js - {"printWidth":120} format 1`] = `
====================================options=====================================
parsers: ["babel", "flow", "typescript"]
printWidth: 120
@@ -38,7 +38,7 @@ const writer = new BufferStackItem(
================================================================================
`;
exports[`issue-7884.js format 1`] = `
exports[`issue-7884.js - {"printWidth":120} format 1`] = `
====================================options=====================================
parsers: ["babel", "flow", "typescript"]
printWidth: 120
@@ -1,82 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`html-template-literals.js format 1`] = `
====================================options=====================================
parsers: ["babel", "flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
const nestedFun = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\`<div>\\\${innerExpr(1)} \${outerExpr(2)}</div>\\\`;
</script>\`;
const nestedFun2 = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\`\\\\n<div>\\\${innerExpr(1)} \${outerExpr(2)}</div>\\\\n\\\`;
</script>\`;
setFoo(
html\`<div>one</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
setFoo(
html\`<div>
<div>nested</div>
</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
setFoo(
html\`<div>
<div>nested</div>
</div>\`,
secondArgument
);
=====================================output=====================================
const nestedFun = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\`<div>\\\${innerExpr(1)} \${outerExpr(2)}</div>\\\`;
</script>\`;
const nestedFun2 = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\` <div>\\\${innerExpr(1)} \${outerExpr(2)}</div> \\\`;
</script>\`;
setFoo(
html\`<div>one</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
setFoo(
html\`<div>
<div>nested</div>
</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
setFoo(
html\`<div>
<div>nested</div>
</div>\`,
secondArgument
);
================================================================================
`;
exports[`html-template-literals.js format 2`] = `
exports[`html-template-literals.js - {"htmlWhitespaceSensitivity":"ignore"} format 1`] = `
====================================options=====================================
htmlWhitespaceSensitivity: "ignore"
parsers: ["babel", "flow", "typescript"]
@@ -167,214 +91,83 @@ setFoo(
================================================================================
`;
exports[`lit-html.js format 1`] = `
exports[`html-template-literals.js format 1`] = `
====================================options=====================================
parsers: ["babel", "flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import { LitElement, html } from '@polymer/lit-element';
class MyElement extends LitElement {
static get properties() {
return {
mood: { type: String }
};
}
constructor() {
super();
this.mood = 'happy';
}
render() {
return html\`
<style
>
.mood { color: green; }
</style
>
Web Components are <span
class="mood" >\${
this.mood
}</span
>!
\`;
}
}
customElements.define('my-element', MyElement);
const someHtml1 = html\`<div > hello \${world} </div >\`;
const someHtml2 = /* HTML */ \`<div > hello \${world} </div >\`;
html\`\`
html\`<my-element obj=\${obj}></my-element>\`;
html\` <\${Footer} >footer content<// > \`
html\` <div /> \`
html\`
<div />
\`
html\`<span>one</span><span>two</span><span>three</span>\`;
function HelloWorld() {
return html\`
<h3>Bar List</h3>
\${bars.map(bar => html\`
<p>\${bar}</p>
\`)}
\`;
}
const trickyParens = html\`<script> f((\${expr}) / 2); </script>\`;
const nestedFun = /* HTML */ \`\${outerExpr( 1 )} <script>const tpl = html\\\`<div>\\\${innerExpr( 1 )} \${outerExpr( 2 )}</div>\\\`</script>\`;
const closingScriptTagShouldBeEscapedProperly = /* HTML */ \`
<script>
const html = /* HTML */ \\\`<script><\\\\/script>\\\`;
</script>
\`;
const closingScriptTag2 = /* HTML */ \`<script>const scriptTag='<\\\\/script>'; <\\/script>\`;
html\`
<div style="
\${ foo}
"></div>
\`
html\`
<div style=\${
foo
}></div>
\`
html\`<div style=" color : red;
display :inline ">
</div>\`
html\`<div style=" color : red;
\${ foo}
display :inline ">
</div>\`
html\`<div style=" color : red;
\${ foo}:\${bar};
display :inline ">
</div>\`
=====================================output=====================================
import { LitElement, html } from "@polymer/lit-element";
class MyElement extends LitElement {
static get properties() {
return {
mood: { type: String },
};
}
constructor() {
super();
this.mood = "happy";
}
render() {
return html\`
<style>
.mood {
color: green;
}
</style>
Web Components are <span class="mood">\${this.mood}</span>!
\`;
}
}
customElements.define("my-element", MyElement);
const someHtml1 = html\`<div>hello \${world}</div>\`;
const someHtml2 = /* HTML */ \`<div>hello \${world}</div>\`;
html\`\`;
html\`<my-element obj=\${obj}></my-element>\`;
html\` <\${Footer}>footer content<//> \`;
html\` <div /> \`;
html\` <div /> \`;
html\`<span>one</span><span>two</span><span>three</span>\`;
function HelloWorld() {
return html\`
<h3>Bar List</h3>
\${bars.map((bar) => html\` <p>\${bar}</p> \`)}
\`;
}
const trickyParens = html\`<script>
f((\${expr}) / 2);
</script>\`;
const nestedFun = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\`<div>\\\${innerExpr(1)} \${outerExpr(2)}</div>\\\`;
</script>\`;
const closingScriptTagShouldBeEscapedProperly = /* HTML */ \`
const nestedFun2 = /* HTML */ \`\${outerExpr(1)}
<script>
const html = /* HTML */ \\\`<script><\\\\/script>\\\`;
</script>
\`;
const tpl = html\\\`\\\\n<div>\\\${innerExpr(1)} \${outerExpr(2)}</div>\\\\n\\\`;
</script>\`;
const closingScriptTag2 = /* HTML */ \`<script>
const scriptTag = "<\\\\/script>";
</script>\`;
setFoo(
html\`<div>one</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
html\`
<div
style="
\${foo}
"
></div>
\`;
html\` <div style=\${foo}></div> \`;
setFoo(
html\`<div>
<div>nested</div>
</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
html\`<div
style=" color : red;
display :inline "
></div>\`;
setFoo(
html\`<div>
<div>nested</div>
</div>\`,
secondArgument
);
html\`<div
style=" color : red;
\${foo}
display :inline "
></div>\`;
html\`<div
style=" color : red;
\${foo}:\${bar};
display :inline "
></div>\`;
=====================================output=====================================
const nestedFun = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\`<div>\\\${innerExpr(1)} \${outerExpr(2)}</div>\\\`;
</script>\`;
const nestedFun2 = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\` <div>\\\${innerExpr(1)} \${outerExpr(2)}</div> \\\`;
</script>\`;
setFoo(
html\`<div>one</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
setFoo(
html\`<div>
<div>nested</div>
</div>
<div>two</div>
<div>three</div>\`,
secondArgument
);
setFoo(
html\`<div>
<div>nested</div>
</div>\`,
secondArgument
);
================================================================================
`;
exports[`lit-html.js format 2`] = `
exports[`lit-html.js - {"htmlWhitespaceSensitivity":"ignore"} format 1`] = `
====================================options=====================================
htmlWhitespaceSensitivity: "ignore"
parsers: ["babel", "flow", "typescript"]
@@ -621,3 +414,210 @@ html\`
================================================================================
`;
exports[`lit-html.js format 1`] = `
====================================options=====================================
parsers: ["babel", "flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
import { LitElement, html } from '@polymer/lit-element';
class MyElement extends LitElement {
static get properties() {
return {
mood: { type: String }
};
}
constructor() {
super();
this.mood = 'happy';
}
render() {
return html\`
<style
>
.mood { color: green; }
</style
>
Web Components are <span
class="mood" >\${
this.mood
}</span
>!
\`;
}
}
customElements.define('my-element', MyElement);
const someHtml1 = html\`<div > hello \${world} </div >\`;
const someHtml2 = /* HTML */ \`<div > hello \${world} </div >\`;
html\`\`
html\`<my-element obj=\${obj}></my-element>\`;
html\` <\${Footer} >footer content<// > \`
html\` <div /> \`
html\`
<div />
\`
html\`<span>one</span><span>two</span><span>three</span>\`;
function HelloWorld() {
return html\`
<h3>Bar List</h3>
\${bars.map(bar => html\`
<p>\${bar}</p>
\`)}
\`;
}
const trickyParens = html\`<script> f((\${expr}) / 2); </script>\`;
const nestedFun = /* HTML */ \`\${outerExpr( 1 )} <script>const tpl = html\\\`<div>\\\${innerExpr( 1 )} \${outerExpr( 2 )}</div>\\\`</script>\`;
const closingScriptTagShouldBeEscapedProperly = /* HTML */ \`
<script>
const html = /* HTML */ \\\`<script><\\\\/script>\\\`;
</script>
\`;
const closingScriptTag2 = /* HTML */ \`<script>const scriptTag='<\\\\/script>'; <\\/script>\`;
html\`
<div style="
\${ foo}
"></div>
\`
html\`
<div style=\${
foo
}></div>
\`
html\`<div style=" color : red;
display :inline ">
</div>\`
html\`<div style=" color : red;
\${ foo}
display :inline ">
</div>\`
html\`<div style=" color : red;
\${ foo}:\${bar};
display :inline ">
</div>\`
=====================================output=====================================
import { LitElement, html } from "@polymer/lit-element";
class MyElement extends LitElement {
static get properties() {
return {
mood: { type: String },
};
}
constructor() {
super();
this.mood = "happy";
}
render() {
return html\`
<style>
.mood {
color: green;
}
</style>
Web Components are <span class="mood">\${this.mood}</span>!
\`;
}
}
customElements.define("my-element", MyElement);
const someHtml1 = html\`<div>hello \${world}</div>\`;
const someHtml2 = /* HTML */ \`<div>hello \${world}</div>\`;
html\`\`;
html\`<my-element obj=\${obj}></my-element>\`;
html\` <\${Footer}>footer content<//> \`;
html\` <div /> \`;
html\` <div /> \`;
html\`<span>one</span><span>two</span><span>three</span>\`;
function HelloWorld() {
return html\`
<h3>Bar List</h3>
\${bars.map((bar) => html\` <p>\${bar}</p> \`)}
\`;
}
const trickyParens = html\`<script>
f((\${expr}) / 2);
</script>\`;
const nestedFun = /* HTML */ \`\${outerExpr(1)}
<script>
const tpl = html\\\`<div>\\\${innerExpr(1)} \${outerExpr(2)}</div>\\\`;
</script>\`;
const closingScriptTagShouldBeEscapedProperly = /* HTML */ \`
<script>
const html = /* HTML */ \\\`<script><\\\\/script>\\\`;
</script>
\`;
const closingScriptTag2 = /* HTML */ \`<script>
const scriptTag = "<\\\\/script>";
</script>\`;
html\`
<div
style="
\${foo}
"
></div>
\`;
html\` <div style=\${foo}></div> \`;
html\`<div
style=" color : red;
display :inline "
></div>\`;
html\`<div
style=" color : red;
\${foo}
display :inline "
></div>\`;
html\`<div
style=" color : red;
\${foo}:\${bar};
display :inline "
></div>\`;
================================================================================
`;
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`0-indent.js format 1`] = `
exports[`0-indent.js - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
@@ -54,7 +54,7 @@ text3
================================================================================
`;
exports[`codeblock.js format 1`] = `
exports[`codeblock.js - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
@@ -85,7 +85,7 @@ markdown\\\`
================================================================================
`;
exports[`escape.js format 1`] = `
exports[`escape.js - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
@@ -124,7 +124,7 @@ markdown\`
================================================================================
`;
exports[`issue-5021.js format 1`] = `
exports[`issue-5021.js - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
@@ -208,7 +208,7 @@ text3
================================================================================
`;
exports[`markdown.js format 1`] = `
exports[`markdown.js - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
@@ -269,7 +269,7 @@ export default function ReadMe() {
================================================================================
`;
exports[`single-line.js format 1`] = `
exports[`single-line.js - {"proseWrap":"always"} format 1`] = `
====================================options=====================================
parsers: ["babel"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`jsx-comment.md format 1`] = `
exports[`jsx-comment.md - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -37,7 +37,7 @@ const Foo = () => {
================================================================================
`;
exports[`markdown-preview-enhanced.md format 1`] = `
exports[`markdown-preview-enhanced.md - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -84,7 +84,7 @@ console.log("hello world");
================================================================================
`;
exports[`trailing-comma.md format 1`] = `
exports[`trailing-comma.md - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`jsonc.md format 1`] = `
exports[`jsonc.md - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
@@ -25,7 +25,7 @@ trailingComma: "all"
================================================================================
`;
exports[`trailing_comma.md format 1`] = `
exports[`trailing_comma.md - {"trailingComma":"all"} format 1`] = `
====================================options=====================================
parsers: ["markdown"]
printWidth: 80
Loaded 100 of 143 files, more files were not shown because too many files have changed in this diff. Show more