Skip to content

Instantly share code, notes, and snippets.

View zonzujiro's full-sized avatar

Ivan Tytarenko zonzujiro

View GitHub Profile
const getData = url =>
fetch(url).then(res => {
if (res.ok) {
return res.json();
}
throw new Error(res.statusText);
});
export const fetchPeople = () =>
import React from "react";
import ReactDOM from "react-dom";
import App from "./App";
import * as THREE from "three";
import * as shaders from "./shaders";
const rootElement = document.getElementById("root");
// ReactDOM.render(<App />, rootElement);
let WIDTH = window.innerWidth;
export let tzs = [
"Africa/Abidjan",
"Africa/Accra",
"Africa/Addis_Ababa",
"Africa/Algiers",
"Africa/Asmara",
"Africa/Bamako",
"Africa/Bangui",
"Africa/Banjul",
"Africa/Bissau",
const state = {
translations: {
currentLocale: 'english',
english: {
mainPage: {
submitButton: 'Submit',
},
},
russian: {
mainPage: {
export let axiosInstance = axios.create({
headers: { 'bearer': jwtToken }
})
export const updateInstance = newToken => {
const settings = {
...(newToken & { headers: { 'bearer': newToken } }),
baseUrl: 'google.com'
}
const processRequest = requestPromise => async dispatch => {
const result = async requestPromise()
if (isError(result)) {
dispatch(resetToken())
}
return result
}
export const MyComponentDesignPanelDef = {
title: TranslationKeys.layoutPanel.header,
helpId: 'fcea264b-9c44-449c-b4dc-abe32bf066b5',
customDesignHelpId: '634e6672-89cc-400e-b241-19a85624c352',
};
import { registerWixDataBindings } from 'wix/dbsm-sdk'
const viewerType = 'SelectionTags'
registerWixDataBindings(viewerType, (api: HostAPI) => {
return import('assets-server-url/selection-tags/dbsm.js);
})
import { EditorTypes } from '@wix/ecl-types';
const Translations = {
title: 'dbs_section_title',
};
export const AddressInputDBSMPanel: EditorTypes.IDBSMPanelfinition = {
height: 297,
sections: [
{
function Parent() {
this.name = 'Parent'
}
Parent.prototype.getName = function() {
return `Mr. ${this.name}`
}
function Child() {
Parent.apply(this);