Skip to content

Instantly share code, notes, and snippets.

View mfaridzia's full-sized avatar
📒
storyteller

Muhammad Farid Zia mfaridzia

📒
storyteller
View GitHub Profile
@mfaridzia
mfaridzia / upload.js
Created October 7, 2021 14:04 — forked from virolea/upload.js
Tracking file upload progress using axios
upload(files) {
const config = {
onUploadProgress: function(progressEvent) {
var percentCompleted = Math.round((progressEvent.loaded * 100) / progressEvent.total)
console.log(percentCompleted)
}
}
let data = new FormData()
data.append('file', files[0])
@mfaridzia
mfaridzia / eslint_prettier_airbnb.md
Created March 19, 2020 09:12 — forked from bradtraversy/eslint_prettier_airbnb.md
ESLint, Prettier & Airbnb Setup

VSCode - ESLint, Prettier & Airbnb Setup

1. Install ESLint & Prettier extensions for VSCode

Optional - Set format on save and any global prettier options

2. Install Packages

npm i -D eslint prettier eslint-plugin-prettier eslint-config-prettier eslint-plugin-node eslint-config-node
@mfaridzia
mfaridzia / .gitlab-ci.yml
Created March 13, 2020 07:42 — forked from superjose/.gitlab-ci.yml
This is an example of a .gitlab-ci.yml that is required for Continuous Integration on GitLab projects.
# Reference: https://www.exclamationlabs.com/blog/continuous-deployment-to-npm-using-gitlab-ci/
# GitLab uses docker in the background, so we need to specify the
# image versions. This is useful because we're freely to use
# multiple node versions to work with it. They come from the docker
# repo.
# Uses NodeJS V 9.4.0
image: node:9.4.0
# And to cache them as well.
@mfaridzia
mfaridzia / front-end-guidelines.md
Created October 13, 2018 10:01 — forked from stowball/front-end-guidelines.md
Front-End Guidelines
@mfaridzia
mfaridzia / kulgram-inventory-quiz.sql
Created December 22, 2016 12:40 — forked from hidayat365/kulgram-inventory-quiz.sql
script sql untuk tantangan membuat query kartu stok
-- tabel master barang
create table items (
id int auto_increment not null,
code varchar(50) not null,
name varchar(200) not null,
primary key (id),
constraint ak_items unique key (code)
);
-- tabel transaksi barang masuk