Oracle Cloud Infrastructure offers an S3 compatible API for object storage.
This example will show you how to use it with the AWS Go SDK
Endpoint
.embed-responsive { | |
@apply relative; | |
} | |
.embed-responsive::before { | |
@apply block; | |
content: ""; | |
} | |
.embed-responsive .embed-responsive-item, |
const firebase = require('firebase'); | |
function getCurrentEventsByStateForAdmins(state) { | |
const db = firebase.firestore(); | |
db.collection('events') | |
.orderBy('expirationDate', 'asc') | |
.where('expirationDate', '>', new Date().toISOString()) | |
.where('state', '==', state) | |
.where('isAdmin', '==', true) |
const MarkdownArray = [ | |
// `<Comment />`. | |
{ syntax: /^\/\/(.*)(?:$|\n)/, | |
parser: (key, [children]) => <Comment key={key} children={parseText(children)} /> }, | |
// `<Header />`. | |
{ syntax: /^(#{1,6})( .*)(?:$|\n)/, | |
parser: (key, [open, children]) => <Header key={key} open={open} children={parseText(children)} /> }, |
Superior to similar solutions. Doesn't use electron or cgo. Easy communication between Go and Js. Can easily use libs like React, Vue and Angular.
This is a demo app using GUI library https://github.com/zserge/lorca which requires only Chrome and might even work with Firefox in the future.
hitTool = new paper.Tool(); | |
hitTool.activate(); | |
hitTool.onMouseDown = function (event) { | |
hitOptions = { | |
segments: true, | |
stroke: true, | |
fill: true, | |
tolerance: 5 | |
}; | |
hitResult = paper.project.hitTest(event.point, hitOptions); |
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
import { useEffect, useReducer } from 'react'; | |
type State<TState, TEffect> = TState & { | |
effects?: TEffect[]; | |
}; | |
export type UseFsmReducerEffects<TAction, TEffect extends { type: string }> = { | |
[K in TEffect['type']]: (params: { | |
effect: Extract<TEffect, { type: K }>; | |
dispatch: (action: TAction) => void; |
// styled component version | |
const Container = styled.div` | |
/*all of the styles*/ | |
` | |
function MyComponent() { | |
return <Container>{/*other stuff*/}</Container> | |
} | |
// css prop version |
import log from "ololog" | |
class Grid { | |
rows = [] | |
width = 0 | |
height = 0 | |
chars = { | |
active: ["┌", "─", "┒", "┃", "┛", "━", "┕", "│"], | |
inactive: ["┌", "─", "┐", "│", "┘", "─", "└", "│"], |