All Questions
421
questions
0
votes
0
answers
49
views
How do I create an Angular Project using the CLI that uses Pug3?
I created a project using the following...
ng new my-app
cd my-app
npx ng add ng-cli-pug-loader
But I get
.../my-app on branch main > npx ng add ng-cli-pug-loader
npm WARN cli npm v10.2.3 does not ...
0
votes
1
answer
334
views
how to add target blank in angularjs script
I'm a little confused. I have to add a target="_blank" to my a. The problem is that tag a has an appeal to a script in angular. I don't know this js framework. I tried to find in ...
0
votes
0
answers
250
views
How to insert raw Pug code in HTML file (external file or inside the HTML file)
I want to put some multiline Pug into an HTML file but I can't find info on how to do this. I am using Angular and also new to programming.
var cards = [{ title: 'Mountain View', copy: 'Check out all ...
0
votes
1
answer
74
views
'Unexpected token { at Function (<anonymous>)' error seen while running iteration on .pug
I want to display an array of strings via pop up screen when an option is clicked. I have created Modal service and passing the elements.
Modal Service:
module.exports =
function ...
0
votes
1
answer
21
views
AngularJS ng-click attribute not updating on post request within ng-repeat
This is the pug file for the catalog
doctype html
html
head
title Tradecademy
meta(name="viewport", content="width=device-width, initial-scale=1")
script(src="https://ajax....
0
votes
1
answer
74
views
Create a Function to update a Table
I am trying to write a function that is used on ng-change in the Pug file in the select Drop down.
This function needs to update the table (id = availableFlight) to show a list of all flights where ...
1
vote
1
answer
155
views
Removing single quotes around downgraded angular 2 component's properties causes strange behavior
I have a downgraded angular 2 component that works fine in an AngularJS component until I remove the single quotation marks around the component's second property.
EDIT: This filetype this component ...
1
vote
0
answers
140
views
csrf() 403 forbidden error when upgraded nodejs from 0.10 to 10.15.1
We have upgraded node js version from 0.10.16 to 10.15.1 in our mean (mysql express angularjs and node) application.
csrf() token validating issues are a-raising.
in http://hostname/auth/sign
...
0
votes
1
answer
110
views
Ng-repeat commented out in jade template
I am working on a previously built website and trying to add angular in a Jade template. I am trying to use a simple ng-repeat but it keeps getting commented out. I believe it has something to do with ...
0
votes
0
answers
70
views
ng repeat index doesn't work for jade mixin
I'm using angularJS 1.5.8 ng-repeat with an array of search data. I tried to pass the $index on mixin inside ng-repeat. It showed empty. When I declared variable object through $scope inside ...
4
votes
1
answer
376
views
How to stop page refresh when changing url by history.replacestate in angularjs?
I'm updating my page URL from on a span click in my angularjs+jade+nodejs application.
http://192.xxx.0.xxx:7071/page-1/blog
to
http://192.xxx.0.xxx:7071/page-2/blog
I am using history.replaceState ...
0
votes
1
answer
66
views
AngularJS ng-repeat does not update the $ctrl in UI
I'm updating my model in applyType method but the items are not reflecting in the UI.
Here is what I'm doing
My model is : model.js
export default function model(
$scope,
) {
...
model.$name = '...
0
votes
1
answer
55
views
Angular not displaying data (Nodejs,Jade)
My app file:
var app = angular.module('app', ['ngRecourse', 'ngRoute']);
app.config(function($routeProvider, $locationProvider){
$routeProvider.when('/', { templateUrl: 'partials/main.jade', ...
0
votes
0
answers
123
views
Define two controller inside angularjs and use pug call data
I want to define 2 controllers (read 2 json) inside 1 js file. And use pug file call back data from 2 json. My code below:
angular.module('shop-menu.controller', []).controller("Shop-menuController", ...
0
votes
2
answers
365
views
How to limit the objects in angularjs ng-repeat?
My $scope values:
I am getting array values in $scope.articles
Example: $scope.articles values looks like:
[
{
date: 'some',
category: [ {name: "Sports"}, {name: "News"}, {name: "Cinema"}...