We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e70e461 commit a91ff28Copy full SHA for a91ff28
src/rsg-components/Props/util.js
@@ -5,7 +5,7 @@
5
* @returns {string}
6
*/
7
export function unquote(string) {
8
- return string.replace(/^['"]|['"]$/g, '');
+ return string && string.replace(/^['"]|['"]$/g, '');
9
}
10
11
/**
@@ -38,5 +38,5 @@ export function getType(prop) {
38
39
40
export function showSpaces(string) {
41
- return string.replace(/^\s|\s$/g, '␣');
+ return string && string.replace(/^\s|\s$/g, '␣');
42
0 commit comments