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 type { RequireOneOrNone } from "type-fest" | |
| import { isArray } from "lodash-es" | |
| import type { UserModel } from "@/db/users/types" | |
| import type { ResourceModelMap } from "./interfaces" | |
| import type { PermissionResource, PermissionScope } from "./types" |
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
| #!/bin/bash | |
| ollama_commit_message_prompt="Generate a concise git commit message written in present tense for the following code diff with the given specifications: 1: Commit message must be a maximum of 255 characters. 2: One line of text and no lists of changes. 3: Exclude anything unnecessary such as translation. Your entire response will be passed directly into git commit." | |
| ollama_commit_message_model="mistral" | |
| if [ -n "$OCM_COMMIT_MESSAGE_PROMPT" ]; then | |
| ollama_commit_message_prompt="$OCM_COMMIT_PROMPT" | |
| fi |
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 { debounce } from 'lodash-es' | |
| import type { MaybeRef } from 'vue' | |
| import { computed, reactive, unref, watch } from 'vue' | |
| import { useRoute } from 'vue-router' | |
| import { z } from 'zod' | |
| type PrimitiveZodTypes = | |
| | z.ZodString | |
| | z.ZodNumber | |
| | z.ZodDate |
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://play.tailwindcss.com/mP9gHiRLWq | |
| const plugin = require('tailwindcss/plugin') | |
| /** @type {import('tailwindcss').Config} */ | |
| export default { | |
| theme: { | |
| extend: { | |
| // ... | |
| }, |
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
| find: t\('(.+)'\).toString\(\) | |
| replace: t('$1') |
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 type { MaybeRef } from 'vue' | |
| import { ref, watchEffect } from 'vue' | |
| type UseDialogOptions = { | |
| isOpen: MaybeRef<boolean> | |
| persistent: MaybeRef<boolean> | |
| onClosing?: () => void | |
| onClose?: () => void | |
| animationOptions: MaybeRef<KeyframeAnimationOptions> | |
| dialogKeyframes: MaybeRef<Keyframe[]> |
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
| # =================== | |
| # Variables | |
| # =================== | |
| count = 0 # assign 0 to count | |
| print(count) # prints 0 | |
| count = 1 # assign 1 to count | |
| print(count) # prints 1 | |
| count = 2 # assign 2 to count | |
| print(count) # prints 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
| // https://codepen.io/codercatdev/pen/eYVjxjK | |
| const rating = stars => `★★★★★☆☆☆☆☆`.slice(5 - stars, 10 - stars); |
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 React from 'react' | |
| type StrictContextReturn<T, U = T> = [React.Context<T>, () => U, T] | |
| export function createStrictContext<T>(options: { | |
| errorMessage?: string | |
| name?: string | |
| defaultValue?: T | |
| allowMissingProvider: true | |
| }): StrictContextReturn<T, T | undefined> |
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 priceWidget = document.querySelector('.js-c-product-quick-form'); | |
| var financialInfo = document.querySelector( | |
| '.p-product-page__product-financial-info' | |
| ); | |
| priceWidget.style.position = 'static'; | |
| priceWidget.style.background = 'none'; | |
| priceWidget.style.border = 'none'; | |
| priceWidget.style.marginTop = '25px'; |
NewerOlder