What do you want to save?
Add Code snippet
New code examples
-
CSS 2021-11-10 14:01:16
How to add object in an array using useState
import React, { useState } from 'react'; function App() { const [items, setItems] = useState([]); // handle click event of the button to add item const addMoreItem = () => { &nb... Add solution -
Javascript 2021-11-06 22:48:09
live search using fetch api
const search_input = document.getElementById('search'); const results = document.getElementById('results'); let search_term = ''; let countries; const fetchCountries = async () => { countries = await fetch( 'https://restcountries.eu/rest/... Add solution -
Shell/Bash 2021-11-05 05:40:21
git remove untracked branches
# this is powershell script for Windows execution git checkout master; git remote update origin --prune; git branch -vv | Select-String -Pattern ": gone]" | % { $_.toString().Trim().Split(" ")[0]} | % {git branch -d $_} Add solution -
C# 2021-11-02 08:34:23
parse persian date string to datetime c#
PersianCalendar p = new PersianCalendar(); string PersianDate1 = textBox1.Text; string[] parts = PersianDate1.Split('/', '-'); DateTime dta1 = p.ToDateTime(Convert.ToInt32(parts[0]), Convert.ToInt32(parts[1]), Convert.ToInt32(parts... Add solution -
TypeScript 2021-10-29 07:04:12
google sheets script save A RANGE to csv
function saveAsCSV() { // Prompts the user for the file name var fileName = Browser.inputBox("Save CSV file as (e.g. myCSVFile):"); // Check that the file name entered wasn't empty if (fileN... Add solution -
Other 2021-10-28 16:28:12
open new activity using login form android kotlin
import android.content.Intent import androidx.appcompat.app.AppCompatActivity import android.os.Bundle import android.widget.Button import android.widget.EditText import android.widget.Toast class MainActivity2 : AppCompatActivity() { override fun o... Add solution