-
No-limits, do-what-you-want API for access to 200K+ HD pics.
#APIs #Developer Tools #Web App 31 social mentions
-
Get live headlines from a range of news sources
Import React, { useState, useEffect } from 'react'; function News() { const [articles, setArticles] = useState([]); useEffect(() => { fetch('https://newsapi.org/v2/top-headlines?country=us&apiKey=YOUR_API_KEY') .then(response => response.json()) .then(data => setArticles(data.articles)); }, []); return ( <div> {articles.map((article, index) => ( <div key={index}> <h3>{article.title}</h3> <p>{article.description}</p> <a href={article.url} target="_blank" rel="noopener noreferrer">Read more</a> </div> ))} </div> ); } export default News;.
#APIs #News #Cryptocurrency 49 social mentions
-
JSON Placeholder is a modern platform that provides you online REST API, which you can instantly use whenever you need any fake data.
Import React, { useState, useEffect } from 'react'; function Posts() { const [posts, setPosts] = useState([]); useEffect(() => { fetch('https://jsonplaceholder.typicode.com/posts') .then(response => response.json()) .then(data => setPosts(data)); }, []); return ( <div> <h3>Posts</h3> {posts.map(post => ( <div key={post.id}> <h4>{post.title}</h4> <p>{post.body}</p> </div> ))} </div> ); } export default Posts;.
#Development #Online Services #Web Browsers 160 social mentions