Skip to content

Instantly share code, notes, and snippets.

View kertnik05's full-sized avatar
🏠
Working from home

Kert Rey Nikko S. Lumahang kertnik05

🏠
Working from home
View GitHub Profile
@kertnik05
kertnik05 / typescriptreact.json
Created August 2, 2022 14:19
Visual Studio Code Snippets
{
// Place your snippets for typescriptreact here. Each snippet is defined under a snippet name and has a prefix, body and
// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
// same ids are connected.
// Example:
// "Print to console": {
// "prefix": "log",
// "body": [
// "console.log('$1');",
version: '3'
services:
cypress:
build:
context: './images'
dockerfile: Dockerfile
@kertnik05
kertnik05 / guide.md
Created January 26, 2022 07:31
Dockerize FE (Vue)

spin ka lang muna ng container na may nodeJS pang build mo lang if gnun gusto mo ... pero meron kc ung iba kasama na ung dist sa build ng image pero gnito ung sa prod

docker run -w /usr/www -v path/to/app:/usr/www --name node-builder node:10-slim npm install && npm run build --> install and build (dist)

pag need mo ulit mag install and build docker start -i node-builder tapos kung gusto na serve docker run -d -p 8080:80 --name fe-webserver -v /path/to/dist:/usr/share/nginx/html:ro -d nginx localhost:8080 sa browser

@kertnik05
kertnik05 / .wslconfig
Created June 7, 2021 09:42
WSL Config
[wsl2]
memory=1GB
processors=2
@kertnik05
kertnik05 / Driver.java
Last active November 5, 2020 11:57
Encapsulation
public class Driver
{
public static void main(String[] args)
{
Person person = new Person();
person.setName("John Wick");
person.setAge(30);
System.out.println("Person name is: " + person.getName());
System.out.println("Person age is: " + person.getAge());
@kertnik05
kertnik05 / app.js
Last active July 22, 2020 06:49
Vue Coding Challenge 3 Answer
// Add an onSale property to the product’s data that is used to conditionally render a span that says “On Sale!”
const app = new Vue({
el: '#app',
data: {
product: 'Socks',
description: 'A pair of warm, fuzzy socks',
image: './assets/vmSocks-green-onWhite.jpg',
link: 'somewebsite.com',
inventory: 100,
@kertnik05
kertnik05 / app.js
Created July 22, 2020 06:20
Vue Coding Challenge 2 Answer
//Add a link to your data object, and use
// v-bind to sync it up with an anchor tag in
// your HTML. Hint: you’ll be binding to the
// href attribute.
const app = new Vue({
el: '#app',
data: {
product: 'Socks',
description: 'A pair of warm, fuzzy socks',
@kertnik05
kertnik05 / app.js
Created July 22, 2020 05:58
Vue Coding Challenge 1 Answer
// Add a description to the data object
// with the value "A pair of warm, fuzzy
// socks". Then display the description using
// an expression in an p element, underneath
// the h1.
const app = new Vue({
el: '#app',
data: {
product: 'Socks',
@kertnik05
kertnik05 / index.html
Last active October 5, 2023 21:26
html table cell split diagonally
<!DOCTYPE html>
<html>
<head>
<title>HTML Table Cell Split Diagonally</title>
</head>
<body>
<table>
<tr>
<td>
<div class="c1">A</div>
@kertnik05
kertnik05 / style.css
Created July 7, 2020 12:00
Create diagonal border of a cell
td {
padding: 50px;
border: 2px solid black;
background-image: -webkit-gradient(linear, left top, right bottom, color-stop(49%, white), color-stop(50%, black), color-stop(51%, white));
background-image: -webkit-linear-gradient(top left, white 49%, black 50%, white 51%);
background-image: -o-linear-gradient(top left, white 49%, black 50%, white 51%);
background-image: linear-gradient(to bottom right, white 49%, black 50%, white 51%);
}