Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

github API fetch

fetch('https://api.github.com/users/{YOUR_USERNAME}', { 
2                 headers: {
3                      'Accept' : 'application/vnd.github.v3+json'
4                  }})
5		.then(response => response.json()) //Converting the response to a JSON object
6		.then( data => {
7                    const root = document.querySelector('#root');
8                    root.innerHTML = ` 
9                      <a href="${data.html_url}">Name: ${data.name}</a>
10                     <p>Followers: ${data.followers}</p>
11                  `
12                })
13		.catch( error => console.error(error));
Comment

PREVIOUS NEXT
Code Example
Shell :: zsh: command not found: wine-stable 
Shell :: bash if is link simbolico 
Shell :: wsl2 taking much memory 
Shell :: javascript to exe 
Shell :: pm2 show command 
Shell :: codeigniter 4 db seed 
Shell :: livewire ErrorException Undefined array key "id" 
Shell :: revert local merge 
Shell :: copy folder in ubuntu 
Shell :: html2canvas 
Shell :: brave installation ubuntu 
Shell :: how to close an issue with a commit 
Shell :: git log 
Shell :: add ssh github 
Shell :: git squash commits merge 
Shell :: open files from terminal linux 
Shell :: scan and print all keys redis shell 
Shell :: git revert all commits to pervious commit 
Shell :: gitbash update 
Shell :: boost volume in ubuntu 18.04 
Shell :: change git repository 
Shell :: nasm compile windows 64 
Shell :: install visual studio on ubuntu 
Shell :: How to list manually installed packages in ubuntu 
Shell :: vim open new tabs 
Shell :: android debug keystore windows 
Shell :: react-darkmode-toggler 
Shell :: download docker ubuntu 
Shell :: how to install wine in ubuntu 18.04 
Shell :: git merge branch to master 
ADD CONTENT
Topic
Content
Source link
Name
3+6 =