1 option
Full-Stack Web Development with TypeScript 5 : Craft Modern Full-Stack Projects with Bun, PostgreSQL, Svelte, TypeScript, and OpenAI / Mykyta Chernenko ; foreword by Artem Korchunov.
- Format:
- Book
- Author/Creator:
- Chernenko, Mykyta, author.
- Language:
- English
- Subjects (All):
- Software frameworks.
- TypeScript (Computer program language).
- Web applications--Development.
- Web applications.
- Open source software.
- Physical Description:
- 1 online resource (272 pages) : illustrations
- Edition:
- First edition.
- Place of Publication:
- Birmingham, England : Packt Publishing, [2024]
- Biography/History:
- Chernenko Mykyta: Mykyta Chernenko has over seven years of experience in technology, mainly in full-stack development with a focus on Python and TypeScript. He has also worked with Go, Kotlin, and Dart on various projects. His technical contributions include working on the Azure integration for Nutanix's cluster discovery project and a key engineering role at Factmata, overseeing engineering and infrastructure. Currently, he holds a position as a senior consultant at KodeWorks. In addition to his technical work, Mykyta has mentored over 20 professionals, sharing his knowledge and experience. He is also the author of The Rational Software Engineer and runs a blog with the same name on Hackernoon, where he writes about his insights in the field.
- Summary:
- This book takes you on a journey with TypeScript 5, introducing its nuances and advantages over traditional JavaScript, explaining TypeScript basics, and highlighting the syntax, typing, generics, classes, and interfaces. Expert advice will help you build your understanding of TypeScript's role in modern web applications. You'll gain hands-on experience with the tools required to write full-stack web applications end to end, beginning with setting up the Bun environment for backend development. This book also explores server-side functionality such as authentication, routing, and database integration with PostgreSQL. The second part of the book focuses on the integration of the OpenAI API, demonstrating the use of the GPT API for different use cases. The final part covers frontend development using Svelte, guiding you through UI design, state management, and performance optimization. Each chapter has real-world examples and comparisons to other technologies, providing you with a comprehensive understanding of full-stack development. By the end of this book, you'll have learned how to build modern web applications using TypeScript 5 and confidently tackle full-stack development challenges.
- Contents:
- Cover
- Title Page
- Copyright and Credits
- Foreword
- Contributors
- Table of Contents
- Preface
- Part 1: Introduction to TypeScript
- Chapter 1: TypeScript Fundamentals
- Technical requirements
- Introduction to TypeScript and its evolution
- Key differences between TypeScript and JavaScript
- The advantages of using TypeScript in modern web development
- Basic syntax of TypeScript
- Simple types
- Interfaces
- Summary
- Chapter 2: TypeScript Deep Dive - Typing, Generics, Classes, and Interfaces
- Advanced typing techniques
- Narrowing
- null types
- Function types
- Creating types from other types
- Utility types
- Union types
- Type intersections
- Interface and OOP features
- OOP functionalities
- Generics
- Promises
- Part 2: Backend Development with Bun and TypeScript
- Chapter 3: Configuring a Backend Environment with Bun and Hono
- Introducing Bun
- Introducing Hono
- Setting up the project
- Adding linting and formatting
- Adding middleware
- Handling environment variables
- Discussing the project structure
- Chapter 4: Building Backend Infrastructure with Bun, Hono, and TypeScript
- Implementing in-memory storage
- Defining the interfaces
- Creating database and API types
- In-memory implementation of the interfaces
- Implementing authentication and authorization
- Developing the authentication middleware
- Defining our controllers
- Implementing chat controllers
- Implementing the endpoints
- Combining the endpoints
- Using the index file for calling the function
- Chapter 5: Improving Reliability - Testing and Validation
- Writing validation with Zod
- Adding validation to our authentication endpoints.
- Adding validation to our chat endpoints
- Developing tests with Bun
- Writing tests with Bun's test runner
- Writing tests for our authentication endpoints
- Writing test for our chat endpoints
- Chapter 6: Advanced Backend Development - Security, Throttling, Caching, and Logging
- Managing security aspects
- Adding request throttling
- Writing the middleware
- Implementing the middleware
- Including the middleware in the main app
- Managing the cache
- Writing the cache middleware
- Using the cache middleware in our chat endpoints
- Using logging
- Creating our logger's configuration
- Adding logger to our caching middleware
- Part 3: Integrating PostgreSQL for Data Management
- Chapter 7: PostgreSQL Basics, Storage, and Setup
- Setting up PostgreSQL in Docker
- What are Docker and Docker Compose?
- What is PostgreSQL?
- Creating a database as a Docker container
- Constructing the database schema
- Defining the database schema
- Creating the database schema
- Writing CRUD SQL operations
- Chapter 8: Interacting with PostgreSQL Using Libraries
- Integrating SQL implementation in the codebase
- Writing a class
- Updating a user
- Incorporating SQL implementation into the main function
- Replacing in-memory data storage with a SQL-based solution
- Testing our SQL integrations to ensure reliability
- Chapter 9: Interacting with PostgreSQL Using Prisma ORM
- Introduction to ORMs and Prisma
- Introducing Prisma - our ORM of choice
- Understanding Prisma Migrate
- Handling migrations using Prisma
- Applying the migration to our database
- Interacting with the database using Prisma
- Defining the Prisma Client class.
- Integrating ORM into the main function
- Testing our ORM integration
- Part 4: AI Integration with OpenAI API
- Chapter 10: Basics of Integrating External APIs with TypeScript and Hono
- Introduction to API integration in TypeScript using fetch
- Handling errors and retries
- Validating API correctness
- Chapter 11: Setting Up and Configuring the OpenAI API for the Backend
- Introduction to LLMs and their applications
- Setting up OpenAI API integration
- Integrating the OpenAI API into our backend
- Part 5: Frontend Development with Svelte
- Chapter 12: Introduction to Svelte for Frontend Development
- What is Svelte?
- History of Svelte
- Differentiation from other frameworks
- Learning Svelte fundamentals
- Component composition structure
- Introduction to .svelte file structure
- Reactivity
- Events
- Bindings
- Handling conditionals and iterating arrays
- Props
- Lifecycle
- Stores
- Chapter 13: Setting Up the Svelte Project
- Discussing Vite and SvelteKit
- Exploring the project structure
- Vite configuration file
- TypeScript configuration file
- Svelte configuration file
- Configuring package.json
- HTML entry point
- Main file
- Application title
- Chapter 14: Svelte Chat Application Development
- Writing routes for our application
- Handling authentication logic
- Defining the authentication store
- Implementing Login component
- Implementing Register component
- Developing chat logic
- Creating a parent component
- Implementing the Header component
- Creating the Chat component
- Introducing styling
- Writing application-wide styling
- Styling for our Login and Register components.
- Styling our header component
- Styling the chat container
- Styling for the chat list
- Styling our chat popup creation component
- Styling for specific chats
- Chapter 15: Advanced Svelte Techniques
- Configuring formatting and linting
- ESLint config file
- Prettier file
- Exploring a11y
- The importance of accessibility
- Accessibility rules and best practices in Svelte
- Fixing accessibility issues in our project
- Setting up i18n
- Introducing testing
- Configuring the Vite file
- Exploring our setup file
- Writing a test for our component
- Further reading
- Index.
- Notes:
- Includes bibliographical references and index.
- OCLC-licensed vendor bibliographic record.
- Description based on print version record.
- ISBN:
- 9781835885598
- 1835885594
- 9781835885581
- 1835885586
- OCLC:
- 1452247242
The Penn Libraries is committed to describing library materials using current, accurate, and responsible language. If you discover outdated or inaccurate language, please fill out this feedback form to report it and suggest alternative language.