Skip to main content
The 2024 Developer Survey results are live! See the results

All Questions

Tagged with
0 votes
2 answers
688 views

getting "SyntaxError:" Unexpected token in JSON at position 0 at JSON.parse"

getting "SyntaxError:" Unexpected token in JSON at position 0 at JSON.parse" on fetching data from backend spring boot compressed as gzip in Angular 7 In backend I'm compressing the ...
user11423673's user avatar
0 votes
1 answer
216 views

How to convert XML format to JSON format

I am getting an API response in XML format. How Can I convert XML to object? I getting API response below format. The Element col is not limited. It may be 5 to 10. <xmlformat> <label1&...
CMS Develop's user avatar
0 votes
0 answers
52 views

Read complex JSON data in typescript

Below is JSON Data: var Dataset = [ { "studentname": "Rockey", "age": 13, "average": 8.2, "exam": [{"Status": "Pass", "TimeStamp": "2019-03-12 08:19:50", "...
ResolveError's user avatar
1 vote
3 answers
89 views

How to get filtered the array in json reponse based on condition check with keys in angular 7

I would like to get filterd the particular array alone from the json response when dataID is not matched with the ParentDataID from another array in same json response using typescript feature in ...
user3175778's user avatar
0 votes
1 answer
1k views

How to bind html from JSON API in Angular 8

i am trying to display data from API in Angular 8 But this API include a html code and when i try to show it in the page the html show up without working Like this i am wondering how can i compile ...
Mohamed Atef's user avatar
0 votes
1 answer
288 views

Pass json string having dynamic data as a source to primeNG datatable

I'll be getting json dynamically from service as follows: {"items":[[{"key": "SerialID","value": "P1.M1.T1"},{ "key": "Description", "value": "Dummy Desc 1"},{ "key": "Label", "value": "A123"}],[{...
guravman's user avatar
  • 151
0 votes
2 answers
22 views

Showing data from a json file in Angular

This is my home.component.ts file: import { Component, OnInit } from '@angular/core'; import {HttpClient, HttpResponse, HttpHeaders} from '@angular/common/http'; @Component({ selector: 'app-home', ...
Darko's user avatar
  • 1
0 votes
1 answer
51 views

Display json data with angular 7

I want to display json data on screen with Angular 7. I have an error. Cannot find a differ supporting object '[object Object]' of type 'object'. NgFor only supports binding to Iterables such as ...
Arya's user avatar
  • 43
3 votes
1 answer
2k views

How to get url parameter in activated link in angular 7 and call rest api from service class

I want to fetch data using id field using Get parameters. Follwing is my html url code which is redirecting to specific page but doesn't call the service to fetch rest api <a [routerLink]="['/...
nilay's user avatar
  • 43
0 votes
2 answers
9k views

Converting JSON into XML Angular 7

EDIT: This doesn't work with the xml2js npm package since I want to do the opposite, convert json to xml, not the other way around. I have my API using JSON data format but I also have to save the ...
arturfil's user avatar
  • 450
0 votes
1 answer
269 views

How to store selected checkbox's values in FormGroup in a Dynamic Form

I am getting form components from API. My code is able to generate HTML FORM from JSON. After generating the form and filling the data when I click on submit I am getting below JSON { "Enter Your ...
Abhi's user avatar
  • 674
5 votes
1 answer
5k views

How to generate a HTML FORM from JSON in Angular 7

I want to generate a HTML FORM from below JSON. { "templateName":"C-Learn Survey", "surveyQuestions":[ { "questionTitle":"Enter your name", "questionType":"Text", ...
Abhi's user avatar
  • 674
0 votes
1 answer
1k views

How to generate JSON of a HTML form on submit in Angular 7

I want to generate JSON from a HTML form to store that form template in ms sql database. Please help. <div class="container"> <mat-card> <mat-toolbar color="accent"> <...
Abhi's user avatar
  • 674
0 votes
1 answer
239 views

how to fix 'Property 'dials' does not exist on type 'Object' in typeScript

import { Component, OnInit } from '@angular/core'; import { DashboardService } from 'src/app/provider/dashboard.service'; @Component({ selector: 'app-dashboard', templateUrl: './dashboard....
user10636494's user avatar
0 votes
1 answer
440 views

Making an API throw HTTP errors or return empty objects [closed]

Is is more elegant to make a JSON-API return plain HTTP error codes or empty arrays/objects as JSON to a frontend? Example: 1. Frontend legitimately requests a user profile. 2. The custom permission ...
gekkedev's user avatar
  • 593

15 30 50 per page
1
2 3 4 5