Skip to content

Instantly share code, notes, and snippets.

View vsemozhetbyt's full-sized avatar

Vse Mozhe Buty vsemozhetbyt

View GitHub Profile
@vsemozhetbyt
vsemozhetbyt / re-unicode-properties.js
Created March 5, 2018 02:01
re-unicode-properties.js
'use strict';
const unicodeProperties = {
nonBinaryNames: {
General_Category: [
'Letter',
'Cased_Letter',
'Uppercase_Letter',
'Lowercase_Letter',
'Titlecase_Letter',
@vsemozhetbyt
vsemozhetbyt / js.nomenclature.web.fx.chains.txt
Last active October 29, 2020 18:46
JavaScript Nomenclature Mozilla Firefox Nightly 52.0a1 (2016-10-17) (chains)
window
window["alert"]
window["alert"]["length"]
window["alert"]["name"]
window["AnalyserNode"]
window["AnalyserNode"]["length"]
window["AnalyserNode"]["name"]
window["AnalyserNode"]["prototype"]
window["AnalyserNode"]["prototype"]["constructor"]
window["AnalyserNode"]["prototype"]["fftSize"]
@vsemozhetbyt
vsemozhetbyt / page-evaluateHandle-example.js
Last active February 5, 2020 19:59
page.evaluateHandle() example
'use strict';
const puppeteer = require('puppeteer');
(async function main() {
try {
const browser = await puppeteer.launch();
const [page] = await browser.pages();
await page.goto('https://example.org/');
'use strict';
const puppeteer = require('puppeteer');
(async function main() {
try {
const browser = await puppeteer.launch();
const [page] = await browser.pages();
await page.goto('https://example.org/');
@vsemozhetbyt
vsemozhetbyt / puppeteer-kbb.js
Last active March 22, 2019 02:16
puppeteer for kbb.com
'use strict';
const puppeteer = require('puppeteer');
(async function main() {
try {
const browser = await puppeteer.launch({ headless: false });
const [page] = await browser.pages();
page.setDefaultTimeout(0);
'use strict';
const puppeteer = require('puppeteer');
(async function main() {
try {
const browser = await puppeteer.launch();
const [page] = await browser.pages();
await page.goto('https://www.fmponline.com/ecomm/Shop');
@vsemozhetbyt
vsemozhetbyt / nomenclature.js
Last active January 22, 2019 18:05
JavaScript Nomenclature
/******************************************************************************/
'use strict';
/******************************************************************************/
const nomenclatureTerms = new Set();
const nomenclatureChains = new Set();
const globs = new Map();
const processedObjects = new Set();
/******************************************************************************/
if (typeof window !== 'undefined') {
puppeteer:session SEND ► {"id":1,"method":"Page.enable","params":{}} +0ms
puppeteer:session ◀ RECV {"id":1,"result":{}} +238ms
puppeteer:session SEND ► {"id":2,"method":"Page.getFrameTree","params":{}} +17ms
puppeteer:session ◀ RECV {"id":2,"result":{"frameTree":{"frame":{"id":"A5576C7526C5BE1FF5DFB821A7BBE9AE","loaderId":"E19A01ABD45F2A56D4B17E78EC01F114","url":"
about:blank","securityOrigin":"://","mimeType":"text/html"}}}} +10ms
puppeteer:session SEND ► {"id":3,"method":"Target.setAutoAttach","params":{"autoAttach":true,"waitForDebuggerOnStart":false}} +6ms
puppeteer:session SEND ► {"id":4,"method":"Page.setLifecycleEventsEnabled","params":{"enabled":true}} +2ms
puppeteer:session SEND ► {"id":5,"method":"Network.enable","params":{}} +2ms
puppeteer:session SEND ► {"id":6,"method":"Runtime.enable","params":{}} +2ms
puppeteer:session SEND ► {"id":7,"method":"Security.enable","params":{}} +1ms
/* ************************************************************************** */
// ==UserScript==
// @name News Bookmark Instagram
// @namespace vsemozhetbyt
// @description News Reading from Bookmark in Instagram
// @version 1
// @include https://www.instagram.com/*
// @noframes
// @grant none
// @nocompat Chrome
'use strict';
/******************************************************************************/
console.log('Requiring modules...');
const fs = require('fs');
const path = require('path');
const readline = require('readline');
const exec = require('child_process').execFile;
const execSync = require('child_process').execFileSync;
const jsdom = require('jsdom');