
The code works by taking the search term and trying to locate its exact match in the calendar event description. Let indexOfFirst = str.indexOf(searchTerm) This is a simple starter filter code that searches for a keyword in a Google Calendar event description and skips the notification action if the keyword is not found. This is one of the most common use-cases and fortunately, a simple one to set up let currentHour = () Į(`It's $ Searching for a keyword and skipping an action If you have Applets that notify you about new events or updates from a service, but these notifications are not important enough to wake you up at night, you can use filter code to skip notifications outside your waking hours.

Running Applets only during certain times Let's look at examples of filter code in action.

But what if you want to have more say in when or how exactly this happens?įilter code gives you some control over this logic. Regular Applets have a very straightforward logic to them - when a trigger fires for a new event, an action is always run.
