Home / Companies / Firebase / Blog / January 2018

January 2018 Summaries

4 posts from Firebase

Filter
Month: Year:
Post Summaries Back to Blog
Firebase Realtime Database query-based rules add a query variable to security rules, enabling developers to restrict read access according to query parameters such as ordering, ranges, equality filters, and result limits. For example, rules can require clients to order records by key and retrieve no more than a specified number of entries, preventing broader or differently structured queries from succeeding. The feature can also simplify database designs by allowing per-user access controls on a flat collection: records can contain a user ID field, while rules require authenticated users to query by that field and match their own ID. Query-based rules work alongside existing security rules, allowing teams to adopt them incrementally, and are available through Firebase tools including the console emulator and official documentation.
Jan 26, 2018 618 words in the original blog post.
Firebase Cloud Functions can be tested locally with the Firebase CLI emulator, which simulates HTTPS and other function triggers and automatically reloads changed JavaScript files without requiring redeployment or emulator restarts. TypeScript introduces an additional compilation step before functions can run, but this can be streamlined by using the TypeScript compiler’s watch mode with `tsc --watch`, which detects file changes and incrementally recompiles code automatically. Running the compiler alongside the emulator restores a rapid edit-and-test workflow, and VSCode can launch the watch process through its build tasks interface while displaying compilation results and errors. Because TypeScript watch mode does not run TSLint, developers are encouraged to configure linting separately in their editor to identify potential production issues.
Jan 25, 2018 546 words in the original blog post.
TypeScript support in the Firebase CLI enables developers to write Cloud Functions with optional static typing, modern language features such as classes, generics, enums, and async/await, while remaining compatible with existing JavaScript code. When initialized with TypeScript, Firebase configures development dependencies, build and lint scripts, compiler settings that transform source files from the functions/src directory into ES6 JavaScript, and predeployment hooks that prevent deployment when linting or compilation fails. TSLint is emphasized as a tool for catching common Cloud Functions issues early, especially unhandled promises in database triggers, which must be returned or awaited to ensure functions complete correctly. It also encourages readability and maintainability through rules such as preferring const over var and avoiding shadowed variable names. Developers can receive immediate TSLint feedback in editors such as Visual Studio Code, and can gradually adopt TypeScript by renaming existing JavaScript files to .ts files before introducing additional TypeScript features.
Jan 18, 2018 1,396 words in the original blog post.
Firebase developer advocate reflects on running global hackathons, identifying common participant motivations such as winning prizes, learning technologies with support from Firebase staff, and collaborating with friends. The account also categorizes project approaches into personal hackers who build tools for themselves, opportunity hackers who address practical market needs, technical hackers who explore novel integrations or solutions, and fun hackers who create entertainment-focused projects. Examples include reminder and productivity apps, food ordering and inventory tools, a Kotlin code-evaluating chatbot, and a game based on progressively unblurring images. Although the author once preferred rigorous development practices over rapid prototyping, these experiences demonstrated that quick, imperfect hacks can coexist with disciplined engineering and provide learning, feedback, creativity, and enjoyment.
Jan 12, 2018 1,007 words in the original blog post.