UNPKG

eslint-plugin-unicorn

Version:
7 lines (5 loc) 131 B
'use strict'; module.exports = string => string.replace( /(?<=(?:^|[^\\])(?:\\\\)*)(?<symbol>(?:`|\$(?={)))/g, '\\$<symbol>' );