Skip to content

Instantly share code, notes, and snippets.

View eladcandroid's full-sized avatar

Elad Cohen eladcandroid

  • Web & Android Full Stack Developer
  • Israel
View GitHub Profile
@nzvtrk
nzvtrk / axiosInterceptor.js
Last active December 7, 2023 17:21
Axios create/recreate cookie session in node.js enviroment
/* Basic example of saving cookie using axios in node.js and session's recreation after expiration.
* We have to getting/saving cookie manually because WithCredential axios param use XHR and doesn't work in node.js
* Also, this example supports parallel request and send only one create session request.
* */
const BASE_URL = "https://google.com";
// Init instance of axios which works with BASE_URL
const axiosInstance = axios.create({ baseURL: BASE_URL });
@kerryboyko
kerryboyko / README.md
Last active April 26, 2023 16:08
VueJS Best Practices Guide

Deverus Vue.js Style Guide

Guide for developing Vue.js applications.

v. 0.0.1

Vue.js is an amazing framework, which can be as powerful as Angular or React, the two big heavy hitters in the world of front-end frameworks.

However, most of Vue's ease-of-use is due to the use of Observables - a pattern that triggers re-renders and other function calls with the reassignment of a variable.

@indiesquidge
indiesquidge / express-example.md
Last active November 1, 2023 10:29
Custom port on Express.js

Express.js Example

Setup

This code is a direct copy of the code found on the Express.js site under Getting Started. I just followed installing and hello world from there to get a basic server up and running.

(index.js file)

@magicznyleszek
magicznyleszek / css-selectors.md
Last active March 29, 2024 01:12
CSS Selectors Cheatsheet

CSS Selectors Cheatsheet

Hi! If you see an error or something is missing (like :focus-within for few years :P) please let me know ❤️

Element selectors

Element -- selects all h2 elements on the page

h2 {
@CMCDragonkai
CMCDragonkai / angularjs_directive_attribute_explanation.md
Last active November 29, 2023 15:35
JS: AngularJS Directive Attribute Binding Explanation

AngularJS Directive Attribute Binding Explanation

When using directives, you often need to pass parameters to the directive. This can be done in several ways. The first 3 can be used whether scope is true or false. This is still a WIP, so validate for yourself.

  1. Raw Attribute Strings

    <div my-directive="some string" another-param="another string"></div>
@jgilfelt
jgilfelt / gist:1231694
Created September 21, 2011 09:50
Android - AsyncTask with inline callback boilerplate
private void asyncTaskWithInlineCallback() {
// display UI progress indicator
// ...
new MyAsyncTask() {
protected void onPostExecute(Boolean result) {
// dismiss UI progress indicator
// process the result
// ...
}