What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-11-04 21:14:12
create window electron
const electron = require('electron') const BrowserWindow = electron.remote.BrowserWindow $( "#target" ).click(function() { let win = new BrowserWindow({ show: false }) win.on('close', function () { win = null }) win.loadURL("github.com&... Add solution -
Go 2021-10-29 20:50:09
golang jwt example
package main import "fmt" // example usage func main() { userData := map[string]interface{}{"id": 1, "email": "[email protected]", "github_name": "restuwahyu13"} accessToken, err := ... Add solution -
Other 2021-10-21 09:12:12
queue in golang
// Package queue creates a ItemQueue data structure for the Item type package queue import ( "sync" "github.com/cheekybits/genny/generic" ) // Item the type of the queue type Item generic.Type // ItemQueue the queue of Item... Add solution -
C# 2021-10-19 18:51:04
oauth2 authentication .net core example
using System.Net.Http; using System.Net.Http.Headers; using System.Security.Claims; using System.Text.Json; using Microsoft.AspNetCore.Authentication; using Microsoft.AspNetCore.Authentication.Cookies; using Microsoft.AspNetCore.Authentication.OAuth; usin... Add solution -
Other 2021-10-19 10:14:12
ls-remote --tags --heads ssh://[email protected]/Qix-/node-error-ex.git
"dependencies": { ... "discord.js": "github:vecchiotom/discord.js", ... } Don’t use github: prefix, it is very moody, just use git+https://github.com/user/repo.git. Add solution -
Other 2021-10-18 02:30:10
go validator
// NOTED: if value or key is exist in mapping = error // NOTED: if value or key is not exist in mapping = not error // more validation struct reference follow this link -> https://github.com/go-playground/validator // example usage package main im... Add solution -
Other 2021-10-14 09:44:11
iris web server delete method forbidden
#add below code snapt to iris web-server config # import "github.com/iris-contrib/middleware/cors" cors := cors.New(cors.Options{ AllowedOrigins: []string{"*"}, AllowCredentials: true, AllowedHeaders: []string{"*"}... Add solution