Skip to content

Instantly share code, notes, and snippets.

View brunoksato's full-sized avatar
Focusing

Bruno Sato brunoksato

Focusing
View GitHub Profile
time open high low close volume volumeMA
1591106400 5276 5277 5268.5 5273.5 57857 42831.65
1591106700 5273.5 5275 5266 5267 35026 41934.9
1591107000 5267 5268 5258 5264.5 55046 42325.9
1591107300 5264 5265 5255 5255.5 33245 42392.05
1591107600 5255.5 5257.5 5248.5 5251.5 46470 41793.4
1591107900 5251.5 5259.5 5251 5253.5 30250 40990.9
1591108200 5253 5255.5 5241.5 5250.5 62253 42376.4
1591108500 5250.5 5256.5 5247.5 5252.5 27759 42609.3
1591108800 5252.5 5255.5 5246 5253.5 32077 41409.85
@brunoksato
brunoksato / example.go
Last active May 20, 2020 22:42
manytomany gorm
//struct channel
type Channel struct {
ID uint `json:"id" gorm:"primary_key" settable:"false"`
Title string `json:"t" sql:"not null"`
RelatedSets []Set `json:"rs,omitempty" gorm:"many2many:related_sets;"`
}
//struct Set
@brunoksato
brunoksato / example.go
Created May 20, 2020 22:41
manytomany gorm
//struct channel
type Channel struct {
Title string `json:"t" sql:"not null"`
RelatedSets []Set `json:"rs,omitempty" gorm:"many2many:related_sets;"`
}
//struct Set
type Set struct {
@brunoksato
brunoksato / theme example.js
Created January 17, 2020 00:24
theme example
theme: {
screens: {
sm: '640px',
md: '768px',
lg: '1024px',
xl: '1280px',
},
colors: {
transparent: 'transparent',
black: '#000',
@brunoksato
brunoksato / after.js
Last active November 11, 2019 17:00
before and after
<html
xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:w="urn:schemas-microsoft-com:office:word"
xmlns:m="http://schemas.microsoft.com/office/2004/12/omml"
xmlns="http://www.w3.org/TR/REC-html40">
<head></head>
<body lang=EN-US style='tab-interval:36.0pt'>
<p >&nbsp;</p>
<p >
<span style='background:yellow;mso-highlight:yellow'>Feopfjepwojfopwjefopjwe</span>
//component
<Dropzone
onDrop={async acceptedFiles => {
if (acceptedFiles.length > 1) {
toaster.warning("Limite 1 imagem");
return;
}
const files = [];
for (const file of acceptedFiles) {
@brunoksato
brunoksato / pagina.jsx
Created October 9, 2019 17:13
so pra ve
import React, { useState, useEffect } from "react";
import { toaster, Label, TextInput } from "evergreen-ui";
import ReactQuill from "react-quill";
import styled from "styled-components";
import Dropzone from "react-dropzone";
import { Formik } from "formik";
import { useStore, useActions } from "../../configureStore";
import { Upload } from "../../utils/upload";
import "../../../node_modules/react-quill/dist/quill.snow.css";
@brunoksato
brunoksato / cookie.ts
Created August 29, 2019 15:28
cookie.ts
@brunoksato
brunoksato / xd.js
Created August 27, 2019 19:24
xdxd
import React, { useEffect } from "react"
import Keycloak from 'keycloak-js';
import { KeycloakProvider } from 'react-keycloak';
import { Router } from "@reach/router"
import Home from "./index"
import Login from "./login"
import PrivateRoute from '../components/PrivateRoute'
const keycloakProviderInitConfig = {
onLoad: 'check-sso',
@brunoksato
brunoksato / upload.js
Created July 31, 2019 22:51
Upload AWS s3 in REACT
import AWS from "aws-sdk/global";
import S3 from "aws-sdk/clients/s3";
export const IMAGE_URL = `${process.env.REACT_APP_ASSETS_BUCKET}`;
export const S3_NAME = `${process.env.REACT_APP_ASSETS_BUCKET_NAME}`;
export async function Upload(folder, file) {
const creds = {
bucket: `${S3_NAME}/${folder}`,
access_key: "access_key",