A complete reference for building type-safe, error-handled Nuxt applications using
typescript-result
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 _createError<E extends Error>(reason: unknown): E { | |
| if (reason instanceof Error) | |
| return reason as E | |
| return new Error(String(reason)) as E | |
| } | |
| /** | |
| * Result type for Railway-Oriented Programming pattern. |
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
| RewriteEngine On | |
| RewriteRule ^updates\.json$ updates.php [L] |
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 | |
| declare(strict_types=1); | |
| use Tracy\Debugger; | |
| const ROOT = __DIR__ . '/../'; | |
| require ROOT . '/vendor/autoload.php'; |
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
| HISTFILE=~/.zsh_history | |
| HISTSIZE=50000 | |
| SAVEHIST=50000 | |
| HIST_STAMPS="mm/dd/yyyy" | |
| setopt HIST_VERIFY | |
| setopt SHARE_HISTORY | |
| setopt APPEND_HISTORY | |
| setopt INC_APPEND_HISTORY | |
| setopt HIST_IGNORE_DUPS |