March 2025 Summaries
11 posts from Convex
Filter
Month:
Year:
Post Summaries
Back to Blog
Hyo Jang shares his experience of rapidly developing a TypeScript-based quiz app using Convex and Expo, leveraging insights from a previous workshop series. By combining Expo, a mature cross-platform framework, with Convex as the backend, Jang efficiently developed and deployed a quiz app to the Play Store and App Store within a month and a half. He highlights key features of his project, including the use of Convex's CQRS architecture for API design, the implementation of email OTP authentication via Convex Auth, and strategies for data migration and seeding. Despite encountering challenges such as the lack of built-in multilingual support and HTML email customization in Convex, Jang managed to implement workarounds and anticipates future updates to address these limitations. His development journey not only deepened his understanding of Convex’s design philosophy but also demonstrated the platform's potential in creating scalable and efficient applications.
Mar 30, 2025
2,084 words in the original blog post.
Ian Macartney reflects on his experiences while attempting to reimplement Mastra Workflows on Convex, a backend with a reactive database. Mastra is a framework for creating agentic workflows, and Macartney's goal was to replicate its behavior using Convex's durable function primitives. He discusses the technical challenges and risks associated with deeply integrating different technologies, highlighting the complexities of mimicking Mastra's features while maintaining seamless operation within Convex. Macartney ultimately decided to abandon his initial approach due to the significant effort required to keep up with Mastra's evolving feature set and instead focused on creating Convex-native components for durable workflows. He shares lessons learned from the project, including the importance of weighing integration strategies carefully and the realization that controlling the entire experience end-to-end might sometimes be more effective than attempting to adapt to an existing platform's evolving interfaces.
Mar 28, 2025
1,700 words in the original blog post.
The text provides an in-depth explanation of how to utilize the convex-helpers library to manage and query data streams in Convex, a backend platform. It covers various techniques to replicate SQL-like operations such as UNION ALL, JOIN, DISTINCT, GROUP BY, and WHERE clauses using TypeScript in Convex. The document introduces the concept of streams, which are async iterables of documents ordered by indexed fields, and explains how to create, merge, and manipulate these streams to achieve complex data querying patterns. It highlights the use of mergedStream to combine data streams, flatMap to expand streams into multiple items, map to modify stream values, and filterWith for advanced filtering with TypeScript predicates. Additionally, the text addresses pagination challenges and solutions, emphasizing the need for stable query definitions and non-reactive contexts to maintain pagination integrity. Overall, the article positions Convex as a comprehensive backend solution with capabilities like cloud functions, a database, and real-time updates to support full-stack AI projects.
Mar 21, 2025
4,074 words in the original blog post.
The article provides a comprehensive guide for developers on translating SQL queries into Convex queries, focusing on building applications like a Slack-like chat app with relational databases. It covers various SQL operations such as UNION, JOIN, DISTINCT, GROUP BY, WHERE clauses, and SELECT fields, demonstrating how these can be effectively translated into Convex queries using TypeScript code. The guide emphasizes the advantages of Convex queries, including guaranteed efficiency, type safety, and reactivity, while offering examples of composing multiple query patterns for complex data retrieval tasks. Additionally, it introduces the Convex QueryStream helper, which facilitates incremental reading of query results, highlighting its role in enhancing performance by ensuring efficient use of indexes and avoiding full table scans. The guide underscores the flexibility and expressive power of Convex queries, allowing for the incorporation of TypeScript checks and async code, and providing more control over database interactions compared to traditional SQL.
Mar 19, 2025
4,427 words in the original blog post.
AI coding is revolutionizing the productivity of developers, as they increasingly leverage AI models to enhance their coding workflows. At Convex, the focus is on evaluating how well large language models (LLMs) can perform specific coding tasks using their reactive database product. This involves understanding the models' ability to write Convex code and addressing issues such as the "knowledge cutoff problem," where LLMs prefer older tools due to pre-training data biases. Convex uses a systematic evaluation method called "evals," which involves tasks, data, and scoring functions to quantitatively measure LLM performance on Convex-specific tasks. The creation of a test suite encompassing fundamentals, data modeling, and other categories has enabled the improvement of AI's coding abilities through prompt engineering, which involves crafting prompts to optimize model output. This approach has shown significant progress in mitigating knowledge cutoff issues without costly fine-tuning. Convex's guidelines, which include specific prompts for using Node.js modules and storage APIs, have improved model performance, highlighting how different models, like Claude and GPT-4o, respond uniquely to prompt tuning. Overall, these evaluations demonstrate the potential of prompt engineering in enhancing AI coding performance, making Convex an attractive platform for building full-stack AI projects.
Mar 19, 2025
2,529 words in the original blog post.
Bobby Alv, a Convex Champion, discusses the development of "ConvexPanel," a tool designed to integrate Convex Dashboard features directly into a developer's environment. Initially, Alv considered creating a Chrome extension to provide quick access to logs, table data, and analytics without leaving the browser. However, due to security and CORS limitations, he pivoted to building a React component that seamlessly embeds within any Convex project. This approach allows direct API integration, secure authentication management, and eliminates the need for switching between browser tabs. ConvexPanel offers functionalities like viewing logs, editing tables, and monitoring app health within the development environment, leveraging modern TypeScript practices and direct API access to ensure data synchronization with the backend. The project aims to enhance efficiency and reduce time wasted on managing multiple browser tabs, inviting contributions and feedback from users to further refine the tool.
Mar 18, 2025
1,213 words in the original blog post.
The comparison of five real-time databases highlights their strengths, limitations, and ideal use cases, aiding developers in selecting the most suitable platform for their applications. Convex is favored for full-stack JavaScript/TypeScript projects requiring real-time synchronization and consistency, especially with React or Next.js, while Firebase Realtime Database is ideal for MVPs and prototypes needing lightweight sync, though it lacks ACID transactions. Supabase offers a familiar SQL-based environment with PostgreSQL, but may experience update lags under load, and Realm caters to offline-first mobile apps with local storage and cloud sync capabilities. InfluxDB is designed for time-series data, excelling in fast ingestion and analytics, but is not suited for CRUD apps or reactive UIs. The choice of a real-time database should align with the specific needs of the development team and the application's goals, with the flexibility to migrate if requirements evolve.
Mar 13, 2025
734 words in the original blog post.
Real-time databases are essential for startups that prioritize speed and user experience, offering a solution to laggy dashboards and unresponsive UIs by automatically syncing data across users, devices, and systems without the need for manual refreshes. Unlike traditional databases that rely on a request/response model, real-time databases use persistent connections, typically through WebSockets, to push updates instantly to subscribed clients, ensuring data is always current and reducing overhead and latency. This architecture is particularly advantageous for collaborative SaaS tools, e-commerce, FinTech, gaming, and IoT applications, where instant data updates enhance user experience and operational efficiency. Convex, a real-time database platform, simplifies the development of real-time applications by using TypeScript for both frontend and backend, offering features like reactive queries, transactional mutations, and built-in developer tools, all while managing the complex infrastructure traditionally required for real-time systems. With Convex, developers can focus on building scalable, responsive applications without the burden of managing infrastructure, making it an appealing choice for startups looking to innovate quickly and effectively.
Mar 12, 2025
2,583 words in the original blog post.
In an engaging and detailed account, Bobby Alv shares his experience of migrating data from MongoDB to Convex, a backend-as-a-service platform, to better meet real-time needs. With a MongoDB database consisting of over 30 tables and 2 million documents, Alv describes the challenges and intricacies of the migration process, which included connecting to both databases, filtering and counting documents, and processing data in manageable batches. The migration involved reformatting data to fit Convex's schema, handling edge cases, and creating new records using Convex mutations. Alv also implemented error handling and a retry mechanism to handle potential issues such as network interruptions. He highlights the importance of batch processing, error handling, and logging, and concludes with insights on the effectiveness of Convex for real-time updates and the overall lessons learned from the migration experience.
Mar 10, 2025
6,398 words in the original blog post.
Authentication is a critical aspect of full-stack application development, with complexities arising from client-side and server-side integration. At ClarityText, using Convex, Clerk, and Next.js, developers faced significant challenges due to authentication race conditions, where unauthenticated requests could bypass security checks, leading to vulnerabilities. To address this, best practices include implementing server-side middleware for early authentication checks, using React hooks like useConvexAuth() for client-side verification, and ensuring database-level authentication within Convex functions. Internal functions in Convex can enhance security by restricting access to sensitive operations. Additionally, customizing hooks and utility functions can simplify authentication logic, reduce code redundancy, and enforce security protocols consistently. Adopting these practices ensures that authentication is handled effectively across different layers, preventing unauthorized access and optimizing application performance.
Mar 06, 2025
4,215 words in the original blog post.
Convex 1.19.5 introduces a beta Model Context Protocol (MCP) server, enabling AI agents to interact with various tools through a standardized protocol, enhancing their ability to safely run code and query data. The MCP server allows agents to introspect deployment tables and functions, execute queries, and manipulate environment variables. It is designed to support AI model coding capabilities by providing sandboxed environments and intuitive tools for querying data without risking database integrity. The server's functionality is exposed through tools compatible with platforms like Cursor, and it supports project-specific and global configurations for broader compatibility. This release aims to improve workflows for autonomous coding by allowing models to efficiently access deployment resources and functions, with future plans to expand toolsets and platform support. Convex positions itself as an all-encompassing backend platform for full-stack AI projects, offering integrated services such as cloud functions, databases, and real-time updates.
Mar 04, 2025
1,219 words in the original blog post.