May 21, 2024, 7:17 p.m. | Rodrigo Oler

DEV Community dev.to

Angular 18 has brought an exciting new feature for developers: the @let directive. This tool helps you create variables quickly and easily within HTML code. Let’s understand how it works and look at some cool examples.





What is @let?


The @let directive allows you to create variables directly in the HTML code. This means you can do simple operations like joining text or calculations without needing to write more complex code elsewhere in your program.





How to Use @let


Here’s …

angular code create developers examples feature front frontend html introduction look tool variables

Senior Data Engineer

@ Displate | Warsaw

Senior Robotics Engineer - Applications

@ Vention | Montréal, QC, Canada

Senior Application Security Engineer, SHINE - Security Hub for Innovation and Efficiency

@ Amazon.com | Toronto, Ontario, CAN

Simulation Scientist , WWDE Simulation

@ Amazon.com | Bellevue, Washington, USA

Giáo Viên Steam

@ Việc Làm Giáo Dục | Da Nang, Da Nang, Vietnam

Senior Simulation Developer

@ Vention | Montréal, QC, Canada