Template strings, without the superfluous whitespace.
The indenation is readjusted to be level with whatever the first line's indentation is. Leading and trailing whitespace is also removed (blanks and newlines).
const preformatted = ;;
Normal template string:The cat goes'meow'Preformatted template string:The cat goes'meow'
Install the library
npm install --save-exact @chooie/preformatted
generated/dist/client/bundle.jsto your project and include it in a script tag on the desired page
- If using Browserify, you can include the source at
View the available tasks to run
Run on your local machine
Run within Docker
Install docker (I'm running 18.03.0-ce-mac60)
Start the Karma server./docker-tasks.sh karma
Capture the browsers you want to test by visiting http://localhost:9876
Run all the checks./docker-tasks.sh test:all
Start the application./docker-tasks.sh run
Frontend testing requirements
In order to perform cross-browser testing professionally, we must test our application in real browsers. The testing infrastructure checks that the expected browsers are tested. You will need to install the necessary browsers and run the necessary emulators(or test loosely - see the error message).
I recommend that you test all browsers/platforms that you intend to serve as part of the automated testing.
With this in place, make sure to start the karma server and capture each of the browsers you would like to test by visiting http://localhost:9876 (may differ if you are in an emulator - read the docs for that environment).
When limiting the mocha tests that you want to run with
make sure to use the
test:quick task first to get a passing suite (WITH NO
LIMITS SPECIFIED YET). Then limit your tests and run
There is something weird going on with our jake test tasks, mocha, and/or karma
that is stopping this from working properly (like with