In some cases I want to capture snapshots without the styles. I just want the rendered DOM.
I'm wondering if you'd be interested in supporting this?
I can accomplish what I want with this diff
// line 127 of src/styleSheetSerializer.js
- const code = print(val);
- let result = `${style}${style ? '\n\n' : ''}${code}`;
+ let result = print(val);
But it'd be nice to have some way to configure jest-styled-components to do this per test.
I had something like this in mind
let result;
if (global.stripStyles) {
result = code;
} else {
result = `${style}${style ? '\n\n' : ''}${code}`;
}
In some cases I want to capture snapshots without the styles. I just want the rendered DOM.
I'm wondering if you'd be interested in supporting this?
I can accomplish what I want with this diff
But it'd be nice to have some way to configure
jest-styled-components
to do this per test.I had something like this in mind