Giter Club home page Giter Club logo

angular-complete-guide-debugging's Introduction

Section 2: Debugging

This is one of several repos that I created for the course "Angular - The Complete Guide (2022 Edition)". For a complete list of repos created for this course: https://gist.github.com/christophervigliotti/92e5b3b93cbe9d630d8e9d81b7eb6636 .

63. Debugging Code in the Browser Using Sourcemaps

https://www.udemy.com/course/the-complete-guide-to-angular-2/learn/lecture/6656260

The Error

No error...but last server cnanot be deleted

The Solution

change const position = id + 1; to const position = id;

62. Understanding Angular Error Messages

https://www.udemy.com/course/the-complete-guide-to-angular-2/learn/lecture/6656252

The Error

when clicking the Add Server button

core.js:6210 ERROR TypeError: Cannot read properties of undefined (reading 'push')
    at AppComponent.push.Sy1n.AppComponent.onAddServer (app.component.ts:12)
    at AppComponent_Template_button_click_5_listener (template.html:5)
    at executeListenerWithErrorHandling (core.js:15279)
    at wrapListenerIn_markDirtyAndPreventDefault (core.js:15317)
    at HTMLButtonElement.<anonymous> (dom_renderer.ts:66)
    at ZoneDelegate.invokeTask (zone.js:421)
    at Object.onInvokeTask (core.js:28578)
    at ZoneDelegate.invokeTask (zone.js:420)
    at Zone.runTask (zone.js:188)
    at ZoneTask.invokeTask [as invoke] (zone.js:503)

The Solution

changed this...

export class AppComponent {
  servers;

...to this...

export class AppComponent {
  servers = [];

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.