-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
updated some issues related to snippets
- Loading branch information
1 parent
348cd90
commit 2e7adee
Showing
9 changed files
with
56 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
{ | ||
"Json::decode": { | ||
"prefix": "Json::decode", | ||
"body": "Json::decode(\\$${json}, \\$${asArray = true})$3", | ||
"body": "Json::decode(\\$${1:json}, \\$${2:asArray = ${3|true, false|}})$4", | ||
"description": "Decodes the given JSON string into a PHP data structure." | ||
}, | ||
"Json::encode": { | ||
"prefix": "Json::encode", | ||
"body": "Json::encode(\\$${json}, \\$${asArray = true})$3", | ||
"body": "Json::encode(\\$${1:json}, \\$${2:asArray = ${3|true, false|}})$4", | ||
"description": "Encodes the given value into a JSON string." | ||
}, | ||
"Json::htmlEncode": { | ||
"prefix": "Json::htmlEncode", | ||
"body": "Json::htmlEncode(\\$${value})$3", | ||
"body": "Json::htmlEncode(\\$${1:value})$2", | ||
"description": "Encodes the given value into a JSON string HTML-escaping entities so it is safe to be embedded in HTML code." | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,57 +1,57 @@ | ||
{ | ||
"StringHelper::basename": { | ||
"prefix": "StringHelper::basename", | ||
"body": "StringHelper::basename(\\$${path}, \\$${suffix = ''})$3", | ||
"body": "StringHelper::basename(\\$${1:path}, \\$${2:suffix = ''})$3", | ||
"description": "Returns the trailing name component of a path." | ||
}, | ||
"StringHelper::byteLength": { | ||
"prefix": "StringHelper::byteLength", | ||
"body": "StringHelper::byteLength(\\$${string})$3", | ||
"body": "StringHelper::byteLength(\\$${1:string})$2", | ||
"description": "Returns the number of bytes in the given string." | ||
}, | ||
"StringHelper::byteSubstr": { | ||
"prefix": "StringHelper::byteSubstr", | ||
"body": "StringHelper::byteSubstr(\\$${string}, \\$${start}, \\$${length = null})$3", | ||
"body": "StringHelper::byteSubstr(\\$${1:string}, \\$${2:start}, \\$${3:length = null})$4", | ||
"description": "Returns the portion of string specified by the start and length parameters." | ||
}, | ||
"StringHelper::countWords": { | ||
"prefix": "StringHelper::countWords", | ||
"body": "StringHelper::countWords(\\$${string})$3", | ||
"body": "StringHelper::countWords(\\$${1:string})$2", | ||
"description": "Counts words in a string" | ||
}, | ||
"StringHelper::dirname": { | ||
"prefix": "StringHelper::dirname", | ||
"body": "StringHelper::dirname(\\$${path})$3", | ||
"body": "StringHelper::dirname(\\$${1:path})$2", | ||
"description": "Returns parent directory's path." | ||
}, | ||
"StringHelper::endsWith": { | ||
"prefix": "StringHelper::endsWith", | ||
"body": "StringHelper::endsWith(\\$${path})$3", | ||
"body": "StringHelper::endsWith(\\$${1:path})$2", | ||
"description": "Check if given string ends with specified substring." | ||
}, | ||
"StringHelper::explode": { | ||
"prefix": "StringHelper::explode", | ||
"body": "StringHelper::explode(\\$${string, \\$${delimiter = ','}, \\$${trim = true}, \\$${skipEmpty = false})$3", | ||
"body": "StringHelper::explode(\\$${1:string, \\$${2:delimiter = ','}, \\$${3:trim = ${4|true, false|}}, \\$${5:skipEmpty = ${6|true, false|}})$7", | ||
"description": "Explodes string into array, optionally trims values and skips empty ones" | ||
}, | ||
"StringHelper::startsWith": { | ||
"prefix": "StringHelper::startsWith", | ||
"body": "StringHelper::startsWith(\\$${string}, \\$${with}, \\$${caseSensitive = true})$3", | ||
"body": "StringHelper::startsWith(\\$${1:string}, \\$${2:with}, \\$${3:caseSensitive = ${5|true, false|}})$5", | ||
"description": "Check if given string starts with specified substring." | ||
}, | ||
"StringHelper::truncate": { | ||
"prefix": "StringHelper::truncate", | ||
"body": "StringHelper::truncate(\\$${string}, \\$${with}, \\$${caseSensitive = true})$3", | ||
"body": "StringHelper::truncate(\\$${1:string}, \\$${2:with}, \\$${3:caseSensitive = ${4|true, false|}})$5", | ||
"description": "Truncates a string to the number of characters specified." | ||
}, | ||
"StringHelper::truncateHtml": { | ||
"prefix": "StringHelper::truncateHtml", | ||
"body": "StringHelper::truncateHtml(\\$${string}, \\$${count}, \\$${suffix}, \\$${encoding = false})$3", | ||
"body": "StringHelper::truncateHtml(\\$${1:string}, \\$${2:count}, \\$${3:suffix}, \\$${4:encoding = ${5|true, false|}})$6", | ||
"description": "Truncate a string while preserving the HTML." | ||
}, | ||
"StringHelper::truncateWords": { | ||
"prefix": "StringHelper::truncateWords", | ||
"body": "StringHelper::truncateWords(\\$${string}, \\$${count}, \\$${suffix = '...'}, \\$${asHtml = false})$3", | ||
"body": "StringHelper::truncateWords(\\$${1:string}, \\$${2:count}, \\$${3:suffix = '...'}, \\$${4:asHtml = ${5|true, false|}})$6", | ||
"description": "Truncates a string to the number of words specified." | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
{ | ||
"VarDumper::dump": { | ||
"prefix": "VarDumper::dump", | ||
"body": "VarDumper::dump( \\$${var}, \\$${depth = 10}, \\$${highlight = false})$3", | ||
"body": "VarDumper::dump( \\$${1:var}, \\$${2:depth = 10}, \\$${3:highlight = ${4|true, false|}})$5", | ||
"description": "Displays a variable." | ||
}, | ||
"VarDumper::dumpAsString()": { | ||
"prefix": "VarDumper::dumpAsString()", | ||
"body": "VarDumper::dump( \\$${var}, \\$${depth = 10}, \\$${highlight = false})$3", | ||
"body": "VarDumper::dump( \\$${var}, \\$${depth = 10}, \\$${highlight = ${5|true, false|}})$3", | ||
"description": "Returns the values of a specified column in an array." | ||
}, | ||
"VarDumper::export": { | ||
"prefix": "VarDumper::export", | ||
"body": "VarDumper::export(\\$${var})$3", | ||
"body": "VarDumper::export(\\$${1:var})$2", | ||
"description": "Exports a variable as a string representation." | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters