next
Round
Technologies
Experiences
Contribute
Login
next
Round
Technologies
Experiences
Contribute
Login
Question Loading...
Pipes
1. What is a pipe in NestJS and what are its two primary uses?
Level: Expert | Frequency: High
2. How does ValidationPipe work with class-validator and class-transformer in NestJS?
Level: Expert | Frequency: High
3. How do you write a custom pipe for parsing and validating a MongoDB ObjectId param in NestJS?
Level: Expert | Frequency: High
4. What is the difference between applying a pipe at the param level vs handler level vs globally in NestJS?
Level: Expert | Frequency: High
5. What interface must a custom pipe implement and what does the transform() method receive?
Level: Expert | Frequency: High
6. What is the difference between a transformation pipe and a validation pipe in NestJS?
Level: Expert | Frequency: High
7. What are all the built-in pipes NestJS ships with?
Level: Expert | Frequency: High
8. How do you pass options to a built-in pipe like ParseIntPipe or ParseUUIDPipe in NestJS?
Level: Expert | Frequency: High
9. Can a pipe be asynchronous in NestJS and how do you implement one?
Level: Expert | Frequency: High
10. What is class-validator and how does it integrate with NestJS ValidationPipe?
Level: Expert | Frequency: High
11. What is the @ValidateNested() decorator and when must you pair it with @Type()?
Level: Expert | Frequency: High
12. How do you write a custom class-validator decorator in NestJS?
Level: Expert | Frequency: High
13. How do you write an async custom validator that checks uniqueness against a database in NestJS?
Level: Expert | Frequency: High
14. How do you validate arrays and conditional fields with class-validator in NestJS?
Level: Expert | Frequency: High
15. What is class-transformer and how does it complement class-validator in NestJS?
Level: Expert | Frequency: High
16. What does @Exclude() and @Expose() do and how do you use them to strip sensitive fields from responses?
Level: Expert | Frequency: High
17. What does the @Transform() decorator do in class-transformer and when should you use it?
Level: Expert | Frequency: High
18. What is the excludeExtraneousValues option in class-transformer and how does it differ from whitelist in ValidationPipe?
Level: Expert | Frequency: High
19. How does @Type() interact with discriminated unions and polymorphic DTOs in class-transformer?
Level: Expert | Frequency: High
20. How do you write a custom pipe that sanitizes a string input (trim and lowercase) in NestJS?
Level: Expert | Frequency: High
21. How do you write a pipe that validates and parses a date string from a route parameter in NestJS?
Level: Expert | Frequency: High
22. How do you make a custom pipe configurable by accepting constructor options in NestJS?
Level: Expert | Frequency: High
23. How do you write a pipe that uses metatype to skip validation for primitive types the same way ValidationPipe does?
Level: Expert | Frequency: High
24. What are the two ways to register a global pipe in NestJS and what is the difference?
Level: Expert | Frequency: High
25. What are all the significant ValidationPipe options and what does each do in NestJS?
Level: Expert | Frequency: High
26. How do you customise the error response format produced by ValidationPipe in NestJS?
Level: Expert | Frequency: High
27. How do you use validation groups with class-validator to apply different rules for create vs update operations in NestJS?
Level: Expert | Frequency: High
28. How do you unit test a custom pipe in NestJS?
Level: Expert | Frequency: High
29. How do you handle file upload validation with ParseFilePipe and custom file validators in NestJS?
Level: Expert | Frequency: High
All Topics
Basics
Modules
Decorators
Controllers
Dependency Injection
Providers
Architecture
Request Lifecycle
Middleware
Guards
Interceptors
Pipes
Filters
Exception Handling
API Design
GraphQL
Database and ORM
Microservices
Authentication and Authorization,
Interceptors