This file contains 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 { useRef } from "react"; | |
import { Canvas } from "react-three-fiber"; | |
function Demo() { | |
const circleRef = useRef(); | |
return ( | |
<> | |
<mesh | |
rotation={[4, 0.3, -0.3]} |
This file contains 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
// ref: https://github.com/torvalds/linux/blob/master/lib/crc64.c#L51 | |
function crc64(str) { | |
const CRC64_ECMA182_POLY = 0x42f0e1eba9ea3693n | |
// CRC64 lookup table | |
const crc64Table = [] | |
for (let i = 0n; i < 256n; i++) { | |
let crc = 0n | |
let c = i << 56n |
This file contains 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
<svg viewBox="0 0 300 300" version="1.1"> | |
<g> | |
<rect | |
x={0} | |
y={0} | |
width={20} | |
height={20} | |
fill="red" | |
id="show" | |
pointerEvents={'visible'} |
This file contains 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
<template> | |
<div class="row"> | |
<div class="col"> | |
<h3>src</h3> | |
<div> | |
<div | |
v-for="el in srcList" | |
:key="el.id" | |
draggable="true" | |
@dragstart="dragStart(el.id, $event)" |
This file contains 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
package main | |
import ( | |
"fmt" | |
"strconv" | |
"strings" | |
) | |
const pwdLen = 4 |