国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。
Dockerized 实践 https://github.com/y0ngb1n/dockerized
| // Website you intended to retrieve for users. | |
| const upstream = 'api.openai.com' | |
| // Custom pathname for the upstream website. | |
| const upstream_path = '/' | |
| // Website you intended to retrieve for users using mobile devices. | |
| const upstream_mobile = upstream | |
| // Countries and regions where you wish to suspend your service. |
| import dynamic from "next/dynamic"; | |
| import Head from "next/head"; | |
| import React, { Suspense, useEffect, useRef, useState } from "react"; | |
| const HLSPlayer = dynamic(() => import("@components/HLSPlayer"), { | |
| suspense: true, | |
| }); | |
| const Parent = () => { | |
| const [video, setVideo] = useState<HTMLVideoElement | null>(null); // use callback state instead of ref due to hydration of SSR stream |
| (require 'org) | |
| (setq-default indent-tabs-mode nil) | |
| (setq org-display-inline-images t) | |
| (setq org-redisplay-inline-images t) | |
| (setq org-startup-with-inline-images "inlineimages") | |
| (setq default-frame-alist | |
| (append (list '(width . 72) '(height . 40)))) |
| # Guitar Tabs Template | |
| # Created by: Ultimate Guitar | |
| # Source URL: https://www.ultimate-guitar.com/lessons/for_beginners/guitar_tabs_template.html | |
| ----------------------------------------------------------------- | |
| SONG NAME - Band Name | |
| ----------------------------------------------------------------- | |
| Tabbed by: | |
| Email: |
| import br.com.radharsomeluz.inventory.configuration.SoftDeletionMongoRepository; | |
| import br.com.radharsomeluz.inventory.configuration.SoftDeletionRepositoryFactoryBean; | |
| import org.springframework.boot.SpringApplication; | |
| import org.springframework.boot.autoconfigure.SpringBootApplication; | |
| import org.springframework.data.mongodb.repository.config.EnableMongoRepositories; | |
| import springfox.documentation.swagger2.annotations.EnableSwagger2; | |
| @SpringBootApplication | |
| @EnableSwagger2 | |
| @EnableMongoRepositories( |
国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。
Dockerized 实践 https://github.com/y0ngb1n/dockerized
| # list available subtitles | |
| # https://superuser.com/questions/927523/how-to-download-only-subtitles-of-videos-using-youtube-dl | |
| youtube-dl --list-subs https://www.youtube.com/watch?v=lmWh9jV_1ac | |
| # download a particular subtitle | |
| youtube-dl --write-sub --sub-lang zh-CN --skip-download https://www.youtube.com/watch\?v\=lmWh9jV_1ac | |
| # download auto generated sub | |
| youtube-dl --write-auto-sub --sub-lang zh-CN --skip-download https://www.youtube.com/watch\?v\=lmWh9jV_1ac |
With the addition of ES modules, there's now no fewer than 24 ways to load your JS code: (inline|not inline) x (defer|no defer) x (async|no async) x (type=text/javascript | type=module | nomodule) -- and each of them is subtly different.
This document is a comparison of various ways the <script> tags in HTML are processed depending on the attributes set.
If you ever wondered when to use inline <script async type="module"> and when <script nomodule defer src="...">, you're in the good place!
Note that this article is about <script>s inserted in the HTML; the behavior of <script>s inserted at runtime is slightly different - see Deep dive into the murky waters of script loading by Jake Archibald (2013)
| # Enable the kube-ps1 oh-my-zsh plugin | |
| plugins = ( | |
| git | |
| kube-ps1 | |
| ) | |
| # The output of the kube_ps1 function is text, so it can be used | |
| # directly as a custom p9k segment | |
| POWERLEVEL9K_CUSTOM_KUBE_PS1='kube_ps1' |
| package ${PACKAGE_NAME}; | |
| import org.springframework.hateoas.Link; | |
| import org.springframework.hateoas.Resource; | |
| public class ${NAME} extends Resource<${ENTITY}> { | |
| public ${NAME}(${ENTITY} content, Link... links) { | |
| super(content, links); | |
| } |