Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
pet the duck until exploded

Oleg Abrazhaev seyfer

💭
pet the duck until exploded
View GitHub Profile
View snippet of package.json scripts
"scripts": {
"serve": "vue-cli-service serve",
"build:admin": "rimraf vue.config.js && copy vue.configAdmin.js vue.config.js && vue-cli-service build --dest dist/admin src/admin/main.js && rimraf vue.config.js && copy vue.configDefault.js vue.config.js",
"build:client": "rimraf vue.config.js && copy vue.configClient.js vue.config.js && vue-cli-service build --dest dist/client src/client/main.js && rimraf vue.config.js && copy vue.configDefault.js vue.config.js",
"lint": "vue-cli-service lint"
},
@Raistlfiren
Raistlfiren / Dockerfile
Last active Jul 15, 2021
XDebug 3 and Docker Reference
View Dockerfile
FROM php:7.4-cli-alpine
# Install xdebug
RUN apk add --no-cache --virtual .phpize-deps $PHPIZE_DEPS \
&& pecl install xdebug \
&& docker-php-ext-enable xdebug \
&& apk del .phpize-deps
WORKDIR /var/www/html
@seyfer
seyfer / gource.sh
Last active Nov 18, 2020 — forked from cgoldberg/gource.sh
Gource - Mir development video
View gource.sh
# install bzr and gource
# get a branch of Mir's trunk code
# create gource video
$ sudo apt-get install bzr gource
$ bzr branch lp:mir
$ cd mir
$ gource \
-s .06 \
View frontend interviews
HTML
- Semantic HTML
- Event delegation
- Accessibility / ARIA
CSS
- Specificity
- Pseudo-elements
- Pseudo-selectors
- Combinators
View data structures and algorithms
Data Structures
- Stacks
- Queues
- Linked lists
- Graphs
- Trees
- Tries
Concepts
- Big O Notation
@IMelker
IMelker / code_format.sh [recursive clang-format]
Last active Jul 26, 2019
clang-format wrapper for multifile ussage [cpp]
View code_format.sh [recursive clang-format]
#!/bin/bash
# ------------------------------------------------------------
# Recursive cpp code formatter based on clang-format
# For base work there is you need to have .clang-format file
#
# USAGE code_format.sh [clang-format-options] [<file|dir> ...]
#
# clang-format-options passes through to clang-format
# ------------------------------------------------------------
View snippet of package.json scripts
"scripts": {
"serve": "vue-cli-service serve",
"build:admin": "rimraf vue.config.js && copy vue.configAdmin.js vue.config.js && vue-cli-service build --dest dist/admin src/admin/main.js && rimraf vue.config.js && copy vue.configDefault.js vue.config.js",
"build:client": "rimraf vue.config.js && copy vue.configClient.js vue.config.js && vue-cli-service build --dest dist/client src/client/main.js && rimraf vue.config.js && copy vue.configDefault.js vue.config.js",
"lint": "vue-cli-service lint"
},
@ejlofgren
ejlofgren / snippet of package.json scripts
Last active Feb 4, 2021
Sample Split Vue Config Files
View snippet of package.json scripts
"scripts": {
"serve": "vue-cli-service serve",
"buildAdmin": "vue-cli-service build --dest dist/admin src/entries/admin_app_entry.js",
"buildMain": "vue-cli-service build --dest dist/public src/entries/main_app_entry.js",
"lint": "vue-cli-service lint"
},
@ofer-papaya
ofer-papaya / fullstory.d.ts
Created Feb 18, 2019
Fullstory API typescript definitions
View fullstory.d.ts
interface Fullstory {
identify(uid: string): void;
setUserVars(userVars: object): void;
getCurrentSessionURL(): string;
log(msg: string);
log(level: string, msg: string);
shutdown();
restart();
consent(consent: boolean);
}
@ibreathebsb
ibreathebsb / upload.js
Last active Jul 23, 2021
file upload from dataUrl with axios
View upload.js
// Note: only for modern browser
import axios from 'axios'
// helper function: generate a new file from base64 String
const dataURLtoFile = (dataurl, filename) => {
const arr = dataurl.split(',')
const mime = arr[0].match(/:(.*?);/)[1]
const bstr = atob(arr[1])
let n = bstr.length
const u8arr = new Uint8Array(n)