So that you can see how OC components look in production before publishing them to production.
Most important features:
<oc-component>container needs to be present in rendered components to make
npm install oh-see
const OhSee = ;const oh =;oh;oh;
var ohSee = new OhSee([NighmareOptions]);
Look at Nighmare.js options.
This is an object with the following structure:
||yes||The component name|
||no||Default 3, is the concurrency of tests|
||no||Allows to specify cookies to be used for each request|
||no||When true, shows stuff in the console|
||no||Allows to specify headers to be used for each request|
||no||An array of nightmareJs actions to perform before the first screenshots. Look at the example below|
||no||An array of nightmareJs actions to perform after the transformation and before the second screenshots. Look at the example below|
||no||Default 3, number of retries after a failing session|
||yes||The path where to save the screenshots|
||no||Default 20000, when the session is going to be restarted|
||yes||The transformation to apply to the component. Look at the Transformation types below|
||yes||The urls to test. Key is used to generate screenshots file name so keep it simple and without spaces and stuff|
Replaces the components' base url to another one. Useful for comparing a local one with the production one.
const transformation =type: 'replaceBaseUrl'oldUrl: ''newUrl: '';...
Where callback is going to have an error and/or a response with the results. If any of the requests fails, the callback will include both an error + the response with succeeding screenshot links.
Yes please. Open an issue first.