Add Event to the google calender
MOHSIN ALI SOOMRO
Posted on October 28, 2021
import makeUrl from "add-event-to-calendar";
export default function App() {
const sendEventToCalender = () => {
const event = makeUrl({
name: `Event name`,
location: "Event location",
details: `Event details`,
startsAt: new Date().toString(),
endsAt: new Date().toString()
});
console.log(event);
window.open(event.google, "_blank");
};
return (
<div className="App">
<h1>Hello CodeSandbox</h1>
<h2>Start editing to see some magic happen!</h2>
<button onClick={sendEventToCalender}>Make urls</button>
</div>
);
}
💖 💪 🙅 🚩
MOHSIN ALI SOOMRO
Posted on October 28, 2021
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.