Skip to content

Instantly share code, notes, and snippets.

View kamilersz's full-sized avatar

kamilersz

View GitHub Profile
@kamilersz
kamilersz / install.sh
Created March 25, 2025 02:43
YT Karaoke Generator - creating instrumental audio file by having youtube link
#!/bin/bash
set -e # Exit on error
echo "Installing dependencies for audio processing tools..."
# Detect OS
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
# Linux installation
echo "Detected Linux system"
<template>
<div>
<b-container>
<b-row>
<b-col md="6" offset-md="3">
<b-form-input placeholder="Masukkan barcode" type="text"
v-model="form.input_barcode"
@keyup.enter="handleSearchBarcode()"
></b-form-input>
</b-col>
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 10.
Fitur Rancangan
1. Input barcode "input type text, v-model=""form.input_barcode"""
1.2. Ketika tombol enter ditekan, cari produk ke list produk. "tambah event handler @keyup.enter=""handleSearchBarcode()"""
1.2.1. Jika produk ditemukan, tambahkan ke list belanjaan "jika searchBarcode() return product, listItems.push(product)"
"1.2.2. Jika produk tidak ditemukan, munculkan pesan error ""Barcode tidak ditemukan""" "jika searchBarcode() return null, munculkan toast error"
2.1. Munculkan looping list belanjaan "v-for=""(item,index) in listItems"" :key=""item.id"""
2.1.1. Munculkan foto produk "binding attribut src ke tag HTML => <img :src=""item.image_url"">"
2.1.2. Munculkan nama produk "gunakan v-text dengan kurung kurawal {{ item.name }}"
2.1.3. Munculkan harga produk "gunakan v-text dengan kurung kurawal, ditambah simbol RP + Vue Filter untuk format uang {{ item.price | formatCurrency }}. Buat juga filter formatCurrency"
3. Input kuantitas produk "binding v-model ke input, dengan attribut ke `item` supaya mas
@kamilersz
kamilersz / todo.vue
Created March 14, 2021 09:10
TodoMVC For Nuxt JS
<template>
<section class="todoapp">
<header class="header">
<h1>todos</h1>
<input class="new-todo"
autofocus autocomplete="off"
placeholder="What needs to be done?"
v-model="newTodo"
@keyup.enter="addTodo">
</header>
@kamilersz
kamilersz / install.bat
Last active April 19, 2025 21:17
Install PWA (or any website) with BAT shortcut on WIndows using Chrome
@ECHO OFF
SETLOCAL
set KEY_NAME="HKLM\Software\Microsoft\Windows\CurrentVersion\App Paths\chrome.exe"
set VALUE_NAME=""
FOR /F "usebackq skip=2 tokens=1,2*" %%A IN (
`REG QUERY %KEY_NAME% /v %VALUE_NAME% 2^>nul`) DO (
set "ValueName=%%A"
set "ValueType=%%B"
set CHROMEPATH="%%C"
@kamilersz
kamilersz / new-phoenix.bat
Created February 24, 2016 22:42
phoenix framework on windows with vue js
mix phoenix.new %1
cd %1
mix deps.get
npm install
npm install babel-preset-es2015 --save
npm install vue --save-dev
npm install vue-strap --save-dev
npm install vue-resource --save-dev
cp node_modules/vue/dist/vue.js web/static/vendor/vue.js
cp node_modules/vue-strap/dist/vue-strap.js web/static/vendor/vue-strap.js