Inspiration
Online harassment has many forms, and one of them is the possibility of the malicious triggering of vulnerable individuals. Trigger warning are becoming more and more mainstream and we wanted a safe space to be available online for such vulnerable users. #HackHarassment
What it does
Trigger Replacer allows the user to type up a list of words that trigger them, and the words they would like them to be replaced with. The user can remove and reset the list of words as they wish, and Chrome will save them for future reference without the user having to input them each time.
How we built it
We used a Chrome extension and their APIs to create a JavaScript code with jQuery elements which is injected on all tabs. An HTML file was made to create the options page of the extension for the user to edit their trigger words.
Challenges we ran into
- Initially the code was run on button click, and we wanted to ensure one click replaced all words and not just one at a time.
- Using regular expressions to exclude elements of the html within tags.
- Asynchronicity of the API callback functions.
- Reading and writing of words using Chrome storage API.
Accomplishments that we're proud of
- Creating something that works from scratch.
- The ability of replacing all instances of the words on the static HTML page.
- Allowing the user to edit the words as they wish.
- Making the internet a safer space.
What we learned
- How to create a Chrome extension.
- Working together with new people on a project with a very tight deadline.
What's next for Trigger Replacer
- Ensuring the extension works on dynamic sites like Facebook or Twitter where the user can scroll (currently only replaces the first few instances of the words)
Log in or sign up for Devpost to join the conversation.