Skip to content

Instantly share code, notes, and snippets.

⚛️
practicing with React

Dmitry Anderson dandgerson

⚛️
practicing with React
Block or report user

Report or block dandgerson

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@dandgerson
dandgerson / Icon.js
Created Oct 26, 2019
Fontawesome react usage
View Icon.js
import React from 'react'
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
import { library } from '@fortawesome/fontawesome-svg-core'
import { faEdit, faCheck, faPen } from '@fortawesome/free-solid-svg-icons'
library.add(
faEdit,
faCheck,
faPen,
)
@dandgerson
dandgerson / EventListener_with_this_as_handler.js
Created Jun 1, 2018
using elem.addEventListener('event', this);
View EventListener_with_this_as_handler.js
getElem() {
if (!this.elem) {
this.render();
}
return this.elem;
}
render() {
let html = _.template('<div class="user-list"></div>')();
this.elem = createElementFromHTML(html);
@dandgerson
dandgerson / index.html
Last active Jun 10, 2019
Assignment: Animate sorting
View index.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title>Template project</title>
<!-- Bootstrap 4 CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/css/bootstrap.min.css" integrity="sha384-rwoIResjU2yc3z8GV/NPeZWAv56rSmLldC3R/AZzGRnGxQQKnKkoFVhFQhNUwEyJ" crossorigin="anonymous">
You can’t perform that action at this time.