UNPKG

@gravityforms/gulp-tasks

Version:
23 lines (17 loc) 371 B
import { Token } from './token.js'; class plainText extends Token { typeText = 'plaintext'; endCondition() { return false; } tokenCondition() { return false; } getContent() { for ( let i = 0; i < this.lines.length; i++ ) { this.lines[ i ] = this.lines[ i ].replace( /^\s+|\s+$/g, '' ); } return this.lines.join( '\n' ); } } export { plainText };