Skip to content

Instantly share code, notes, and snippets.

View tanvirstreame's full-sized avatar
💻
Superman

Tanvir Islam Streame tanvirstreame

💻
Superman
View GitHub Profile
@tanvirstreame
tanvirstreame / button-focus.txt
Last active September 16, 2019 06:29
when button is clicked and focus
.close-button:focus {
background-color: $red !important;
}
@tanvirstreame
tanvirstreame / height.txt
Last active September 16, 2019 10:24
remove height and use min-height only
height: unset;
min-height: 20px;
@tanvirstreame
tanvirstreame / functionBinding.txt
Last active September 17, 2019 11:49
Function binding in reactjs
In react js you can sent send data by props parent to child ,
aslo you can controll parent function from child one
this is in parent-
saveHandler = () => {
}
<VehicleCreateExtraInfoForm
saveHandler={this.saveHandler}
@tanvirstreame
tanvirstreame / virtualenv
Created September 17, 2019 12:02
virtualenv
virtualenv -p python3 envname
@tanvirstreame
tanvirstreame / plotly
Created September 17, 2019 12:25
draw graph
import plotly.express as px
import pandas as pd
df = pd.read_csv('https://raw.githubusercontent.com/plotly/datasets/master/finance-charts-apple.csv')
fig = px.line(df, x='Date', y='AAPL.High')
fig.show()
@tanvirstreame
tanvirstreame / line graph
Created September 17, 2019 12:27
line graph
import plotly.graph_objects as go
import datetime
x = [datetime.datetime(year=2013, month=10, day=4),
datetime.datetime(year=2013, month=11, day=5),
datetime.datetime(year=2013, month=12, day=6)]
fig = go.Figure(data=[go.Scatter(x=x, y=[1, 3, 6])])
# Use datetime objects to set xaxis range
fig.update_layout(xaxis_range=[datetime.datetime(2013, 10, 17),
react js template language with varible
`/static/img/model-kind/${modelKindIconList[item.modelKind]}`
@tanvirstreame
tanvirstreame / react js property object
Created September 17, 2019 12:32
easy way to keep react property to keep under a unique object
best way to keep react js separate group of property is separating is property by separate object
formValue: {
images: [],
kind: ""
},
@tanvirstreame
tanvirstreame / React js windows top
Created September 17, 2019 12:33
React js windows top
window.scroll({top: 0});