This file contains hidden or 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
| var csv = [ | |
| ["id", "nome", "cidade_id"], | |
| [23, "alex", "pereiro"], | |
| [23, "alex", "pereiro"], | |
| [23, "alex", 3], | |
| ] | |
| const col= csv[0][2] // cidade_id | |
| const cel = typeof csv[3][2]; // 3 |
This file contains hidden or 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
| https://askubuntu.com/a/1062404/1386875 | |
This file contains hidden or 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
| const routes = [ | |
| { | |
| route: '/registers/company', | |
| childrens: [ | |
| "/registers/company/:companyId/edit", | |
| "/registers/company/new", | |
| ] | |
| } | |
| ] |
This file contains hidden or 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
| function a(size = 21) { | |
| let urlAlphabet = "sys_abcdefghijklmnopqrstuvwxyz0123456789"; | |
| const length = urlAlphabet.length; | |
| let id = ""; | |
| // A compact alternative for `for (var i = 0; i < step; i++)`. | |
| let i = size; | |
| while (i--) { | |
| // `| 0` is more compact and faster than `Math.floor()`. | |
| id += urlAlphabet[(Math.random() * length) | 0]; | |
| } |
This file contains hidden or 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
| const vars = [{ | |
| name: '{CLIENTE_NOME}', | |
| value: 'Alex Alan Nunes' | |
| }, { | |
| name: '{DATA}', | |
| value: new Date().toLocaleString() | |
| }, { | |
| name: '{PERIODO}', | |
| value: 'manha' | |
| }]; |
This file contains hidden or 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
| function mask(value, pattern) { | |
| let i = 0; | |
| return pattern.replace(/#/g, () => value[i++]||''); | |
| } | |
| mask('08111998', '##/##/####'); | |
| // '08/11/1998' |
This file contains hidden or 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
| <?php | |
| $d1 = '2021-07-01'; | |
| $d2 = '2021-07-10'; | |
| $dados = [ | |
| [ | |
| "data" => "2021-07-01", | |
| "value" => 10, | |
| ], |
This file contains hidden or 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
| * { | |
| box-sizing: content-box | |
| } | |
| .main { | |
| width: 100%; | |
| margin: 0 auto; | |
| display: flex; | |
| border:1px solid #ccc; | |
| } | |
| .left, .right { |
This file contains hidden or 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
| // [1]: ^#.+ => regex para remover comentarios | |
| // [2]: ^\s*$ ou (\n|\s)$ => regex para remover linhas em branco | |
| // [3]: (.+[a-z]|\n)$ => regex para verificar chave sem igual (=) | |
| // file.cfg | |
| // [1] | |
| ####################################################################################### | |
| ## Anonymous ## | |
| ####################################################################################### | |
| account.1.anonymous_call.server_base_only = |
This file contains hidden or 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
| "rules": { | |
| "arrowParens": "always", | |
| "bracketSpacing": true, | |
| "endOfLine": "lf", | |
| "htmlWhitespaceSensitivity": "css", | |
| "insertPragma": false, | |
| "jsxBracketSameLine": false, | |
| "jsxSingleQuote": false, | |
| "printWidth": 220, | |
| "proseWrap": "preserve", |