<script>
const prop = 123;
console.log(prop);
</script>
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
import useSWR from "swr"; | |
type Fetcher<FetchData, FetchKey extends Key> = ( | |
key: FetchKey | |
) => FetcherResponse<FetchData>; | |
type FetcherResponse<FetchData = unknown> = FetchData | Promise<FetchData>; | |
type KeyValue = | |
| string |
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
/** | |
* @see https://prettier.io/docs/en/configuration.html | |
* @type {import("prettier").Config} | |
*/ | |
const config = { | |
/** | |
* Specify the line length that the printer will wrap on. | |
* @default 80 | |
*/ | |
printWidth: 120, |
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
export const Example1 = () => { | |
return ( | |
<Markdown className="terms-text" inline> | |
This is an exmplple of usage for [this gist](https://gist.github.com/Profesor08/63f8a23944cbb98705477198639cd3a5) in react | |
</Markdown> | |
); | |
}; | |
export const Example2 = () => { | |
return ( |
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
import camelCase from "lodash/camelCase"; | |
export const styleToCSSProperties = (style: string = "") => { | |
return style | |
.trim() | |
.split(";") | |
.map((rule) => { | |
const [key, value] = rule.trim().split(":"); | |
return { |
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
class CharacterClass | |
{ | |
private static $characterClasses = [ | |
["code" => 0, "name" => ["full" => "Dark Wizard", "short" => "DW", "group" => "dw"], "itemClass" => "DarkWizard", "classNumber" => 1], | |
["code" => 1, "name" => ["full" => "Soul Master", "short" => "SM", "group" => "dw"], "itemClass" => "DarkWizard", "classNumber" => 2], | |
["code" => 3, "name" => ["full" => "Grand Master", "short" => "GM", "group" => "dw"], "itemClass" => "DarkWizard", "classNumber" => 3], | |
["code" => 7, "name" => ["full" => "Soul Wizard", "short" => "SW", "group" => "dw"], "itemClass" => "DarkWizard", "classNumber" => 4], | |
["code" => 16, "name" => ["full" => "Dark Knight", "short" => "DK", "group" => "dk"], "itemClass" => "DarkKnight", "classNumber" => 1], | |
["code" => 17, "name" => ["full" => "Blade Knight", "short" => "BK", "group" => "dk"], "itemClass" => "DarkKnight", "classNumber" => 2], |
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
<# | |
Hint: Allowing opening tabs in same directory | |
1. Open Windows Terminal settings | |
2. Navigate to Profiles and select one | |
3. Find Starting Directory config | |
4. Activate checkbox "Use parent process directory" | |
5. Repeat 2-4 for all profiles | |
#> | |
if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")) { |