style: formatting
This commit is contained in:
parent
860c36146e
commit
dbbba573e3
3 changed files with 33 additions and 34 deletions
|
|
@ -22,7 +22,9 @@ const GITHUB_API_URL = "https://api.github.com";
|
||||||
|
|
||||||
export async function getRepoStars(owner, repo) {
|
export async function getRepoStars(owner, repo) {
|
||||||
try {
|
try {
|
||||||
const response = await axios.get(`${GITHUB_API_URL}/repos/${owner}/${repo}`);
|
const response = await axios.get(
|
||||||
|
`${GITHUB_API_URL}/repos/${owner}/${repo}`
|
||||||
|
);
|
||||||
return response.data.stargazers_count;
|
return response.data.stargazers_count;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("Error fetching repository data:", error);
|
console.error("Error fetching repository data:", error);
|
||||||
|
|
|
||||||
|
|
@ -14,10 +14,7 @@ export default function ChatInput({
|
||||||
if (!lockChat && inputRef.current) {
|
if (!lockChat && inputRef.current) {
|
||||||
inputRef.current.focus();
|
inputRef.current.focus();
|
||||||
}
|
}
|
||||||
},[
|
}, [lockChat, inputRef]);
|
||||||
lockChat,inputRef
|
|
||||||
])
|
|
||||||
|
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (inputRef.current) {
|
if (inputRef.current) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue