Home / Companies / SuperTokens / Blog / Post Details
Content Deep Dive

Solving Auth for Everyone: The SuperTokens CLI Overhaul

Blog post from SuperTokens

Post Details
Company
Date Published
Author
Darko Bozhinovski
Word Count
1,539
Language
English
Hacker News Points
-
Summary

The create-supertokens-app CLI tool was initially developed as an educational demo tool in 2020 to showcase how SuperTokens can integrate with different tech stacks, but it faced challenges because users expected it to function as a scaffold generator. To align with user expectations and maintain its educational purpose, the team behind the tool embarked on a three-phase refactoring project aimed at transforming it into a dual-purpose CLI that simplifies adding authentication features across various frameworks. Phase 1 focused on achieving consistency across 20 different framework configurations by standardizing routes and configurations, while Phase 2 involved reducing repetitive code through a centralized code generation system using template strings, which the team intends to evolve into an AST-based approach in Phase 3. The ultimate vision is to make SuperTokens easily integrable into existing projects across diverse technologies by allowing users to add authentication features with simple CLI commands, thus supporting the broader goal of making authentication straightforward and customizable for developers.