Learning AngularJS for .NET Developers


Learning AngularJS for .NET Developers
eBook: $20.99
Formats: PDF, PacktLib, ePub and Mobi formats
$16.79
save 20%!
Print + free eBook + free PacktLib access to the book: $55.98    Print cover: $34.99
$34.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Support
Sample Chapters
  • Implement complex frontend applications using AngularJS and rock solid web services using ServiceStack
  • Become a more productive developer and learn to use frameworks that enforce good development practices
  • Follow a gradual introduction to concepts with lots of examples and explore the evolution of a production-ready application

Book Details

Language : English
Paperback : 202 pages [ 235mm x 191mm ]
Release Date : July 2014
ISBN : 1783986603
ISBN 13 : 9781783986606
Author(s) : Alex Pop
Topics and Technologies : All Books, Web Development, Open Source


Table of Contents

Preface
Chapter 1: Introducing AngularJS
Chapter 2: Creating an AngularJS Client-side Application in Visual Studio
Chapter 3: Creating .NET Web Services for AngularJS
Chapter 4: Creating an AngularJS, ASP.NET MVC, ServiceStack Application
Chapter 5: Testing and Debugging AngularJS Applications
Chapter 6: Advanced AngularJS Topics
Index
  • Chapter 1: Introducing AngularJS
    • Presenting AngularJS with examples
      • A jQuery example
      • An AngularJS example
      • Introducing the AngularJS controller
      • An overview of the AngularJS architecture
      • The Model-View-Controller pattern
      • The structure of an AngularJS application
        • Bootstrapping an AngularJS application
        • Defining module dependencies
    • The JavaScript patterns and practices used in AngularJS applications
      • Immediately-invoked Function Expression
      • The revealing module pattern
      • The strict mode of JavaScript
    • Dependency injection
    • Introducing AngularJS services
    • Directives
      • The ngRepeat directive
      • The ngInclude directive
      • Creating a custom directive
    • Filters
    • Summary
  • Chapter 2: Creating an AngularJS Client-side Application in Visual Studio
    • Using Visual Studio with NuGet to manage AngularJS and related libraries
      • Introducing NuGet
      • Using Visual Studio extensions for AngularJS
    • Prototyping client-side components
    • Organizing client-side code
    • Integrating AngularJS with JavaScript libraries
      • Native JavaScript libraries and AngularJS
      • Third-party user interface libraries and AngularJS
    • Routing
    • Creating a bicycle rental management application
      • Creating the application layout
      • Implementing the Bicycles views
        • The Bicycles index view
        • The Bicycles new view
        • The Bicycles edit view
      • Implementing the Customers views
      • Implementing the Rentals views
    • Summary
  • Chapter 3: Creating .NET Web Services for AngularJS
    • RESTful web services
    • Choosing a RESTful web services framework
    • Why ServiceStack is a great fit for AngularJS
    • ServiceStack overview
      • Setting up the ServiceStack starter project
      • Creating ServiceStack web services
      • Using the ServiceStack C# client
      • The ServiceStack infrastructure
        • Routing
        • Request and response filters
        • Dependency injection
        • Automatic validation
    • Creating web service methods for the sample application
      • ServiceStack project structure
      • Implementing Bicycles-related web services
        • The GET web service methods
        • The POST web service method
        • The PUT web service method
        • Merging PUT and POST request DTOs
    • Calling RESTful web services in AngularJS using the ngResource module
      • Using the $resource service
      • Resource class methods
      • Resource instance methods
      • Custom resource methods
    • Summary
  • Chapter 4: Creating an AngularJS, ASP.NET MVC, ServiceStack Application
    • Using ASP.NET MVC as the application backbone
      • Why you should use ASP.NET MVC
      • Adding ASP.NET MVC to the main sample application
      • Integrating ASP.NET MVC with ServiceStack
      • Routing considerations for ASP.NET MVC and AngularJS
      • Using ASP.NET bundling and minification features for AngularJS files
    • Securing the AngularJS application
      • Using the ServiceStack.Mvc library
      • The building blocks of the ServiceStack security infrastructure
      • Introducing the AuthFeature plugin
      • Implementing authentication for web services
      • Implementing authentication for ASP.NET MVC controllers
    • Pushing initial data from the server-side application to the AngularJS application
    • How to ensure that AngularJS works well with the backend
      • Handling the waiting time for long operations
      • Handling exceptions and implementing generic animations
        • Adding a $http interceptor
        • Implementing spinner animations for all web service calls
    • Adding database persistence
      • Adding database persistence to the AuthFeature plugin
      • Adding database persistence for web services
      • Persisting the Bicycle class
      • Changing BicycleRepository to use the OrmLite API
    • Summary
  • Chapter 5: Testing and Debugging AngularJS Applications
    • Overview of testing AngularJS applications
      • Introducing Node.js
      • Setting up the Node.js environment
    • Unit testing AngularJS components
      • Installing Karma
      • Configuring Karma
      • Creating AngularJS unit tests with Jasmine
        • Jasmine essentials
        • Using the ngMock module for the first test
        • Mocking remote server calls with $httpBackend
    • Testing an AngularJS application end to end
      • Installing Protractor
      • Configuring Protractor
      • Writing Protractor tests
    • Testing web service endpoints
      • Configuring self-hosted ServiceStack web services
      • Adding BDD tests with xBehave.net
    • Unit testing .NET code
    • Techniques to debug AngularJS applications
    • Support for HTML5 validation and older browsers such as Internet Explorer 8 and 9
    • Summary
  • Chapter 6: Advanced AngularJS Topics
    • Internationalization and localization
      • Using the ngLocale module
      • Using the angular-dynamic-locale module
      • Other internationalization-related topics
    • Using AngularJS animations
    • Working with remote web services
      • Using JSONP
      • Using CORS
    • Template caching
    • Summary

Alex Pop

Alex Pop is a professional software developer with a university degree in Computer Engineering and 12 years of commercial experience building .NET applications. He has worked for ISVs, building enterprise resource planning applications, content management systems, and insurance and financial software products, and he is currently working in the higher education sector as a web application developer. His developer blog at http://alexvpop.blogspot.co.uk contains technical articles about .NET, JavaScript, and various software engineering topics.

Sorry, we don't have any reviews for this title yet.

Code Downloads

Download the code and support files for this book.


Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.

Sample chapters

You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

Frequently bought together

Learning AngularJS for .NET Developers +    DotNetNuke 5.4 Cookbook =
50% Off
the second eBook
Price for both: ₨430.20

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • Create a standalone AngularJS application to prototype user interfaces
  • Validate complex forms with AngularJS and use Bootstrap to style them
  • Build RESTful web services that work well with single-page applications
  • Implement automatic validation for web service requests to reduce your boilerplate code
  • Use web services with AngularJS to offload and secure your application logic
  • Test your AngularJS and web service code to improve the quality of your software deliverables
  • Structure your JavaScript code and organize your files so your application can grow at a sustainable pace

In Detail

AngularJS is the most popular JavaScript MVC framework, and it embraces and extends HTML rather than abstracting it. The building of single-page applications is a web-designer-friendly process with the AngularJS expressive HTML vocabulary. It drastically reduces the amount of JavaScript required to control complex user interactions and enforces a modular approach to structuring your JavaScript code.

This book covers all of the stages of building a single-page web application, starting with frontend components powered by AngularJS, continuing with web services that leverage ServiceStack, and putting it all together in an ASP.NET MVC application. You will learn a development process focused on rapid delivery and testability for all application layers.

Approach

This is a step-by-step, example-driven guide that uses a gradual introduction of concepts; most of the chapters also contain an annotated exploration of how to build a specific part of a production-ready application.

Who this book is for

If you are a .NET developer that has already built web applications or web services with a fundamental knowledge of HTML, JavaScript, and CSS, and want to explore single-page applications, then this book will give you a great start. The frameworks, tools, and libraries mentioned here will make you productive and minimize the friction usually associated with building server-side web applications.

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software