source:
node_modules/es-toolkit/dist/compat/_internal/isDeepKey.mjs
| Last change on this file was a762898, checked in by , 5 months ago | |
|---|---|
|
|
| File size: 282 bytes | |
| Rev | Line | |
|---|---|---|
| [a762898] | 1 | function isDeepKey(key) { |
| 2 | switch (typeof key) { | |
| 3 | case 'number': | |
| 4 | case 'symbol': { | |
| 5 | return false; | |
| 6 | } | |
| 7 | case 'string': { | |
| 8 | return key.includes('.') || key.includes('[') || key.includes(']'); | |
| 9 | } | |
| 10 | } | |
| 11 | } | |
| 12 | ||
| 13 | export { isDeepKey }; |
Note:
See TracBrowser
for help on using the repository browser.
