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

Questions tagged [string-interpolation]

String interpolation is the replacement of defined character sequences in a string by given values. This representation may be considered more intuitive for formatting and defining content than the composition of multiple strings and values using concatenation operators. String interpolation is typically implemented as a language feature in many programming languages including PHP, Haxe, Perl, Ruby, Python, C# (as of 6.0) and others.

string-interpolation
0 votes
0 answers
23 views

How to avoid of dropdown list takes full screen?

In angular, I did the data interpolation with binding three data from a JSON taken from API calling. But in the case that drop down takes full screen to load that data. How can I change its width as ...
Chinthaka Prasad Wijerathna's user avatar
2 votes
2 answers
89 views

Why does PerlCritic think my prototype is string interpolation?

I have code in a package (class) that has a sorting function with a prototype: #!perl package Foo; use strict; use warnings; sub new { my ($class, $value) = @_; my $self = bless{}, $class; ...
Robert's user avatar
  • 8,138
1 vote
1 answer
70 views

Terraform doesn't let me join a string to a variable in for loop to reference another variable

I am sure this is not a unique requirement and I have delt with this type of issue using eval() syntax in few other programming and scripting environments. My problem: I am trying to create a ...
ankur kapoor's user avatar
0 votes
3 answers
55 views

Angular text interpolation (double curly brackets) not working, the values of the variables are not display

I want to display details of a student, but the values are not showing up on the app. the component: import { Component, OnInit } from '@angular/core'; import { Student } from '../student'; import { ...
Yahya Bekaoui's user avatar
-2 votes
1 answer
168 views

Why does Java's string templating use clumsy STR prefix? [closed]

Java finally supports string interpolation! I'm very happy about it. However, the syntax seems to me a bit clumsy // string templating syntax from Java 23 String greeting = STR."Hello \{name}!&...
Powet's user avatar
  • 157
0 votes
1 answer
25 views

How jenkins resolves credentials without using string interpolation?

I was reading the Jenkins documentation and saw the following example: pipeline { agent any environment { EXAMPLE_CREDS = credentials('example-credentials-id') } stages { ...
Matheus's user avatar
  • 337
1 vote
1 answer
31 views

Overriding HashMap.toString() in string interpolation contexts

I am trying to create a subclass of HashMap with its own string representation. I figured that I just needed to override toString() in the subclass: class Foo extends HashMap { String toString() { ...
Xophmeister's user avatar
  • 9,141
2 votes
1 answer
52 views

Scala how to prevent empty lines in scala interpolated string template?

I have an object with some optional attributes which I want to list in a string template (In a sort of JSON way) If the attribute is None I don't want to see anything, if it is Non None I want to see ...
dr jerry's user avatar
  • 9,948
0 votes
1 answer
35 views

String Interpolation Issue Jupyter Notebook Pyspark

I am passing in the following as a query (.dbtable) to pyspark, running in jupyter notebook on AWS EMR. num = [1234,5678] newquery = "(SELECT * FROM db.table WHERE col = 1234) as new_table" ...
andruidthedude's user avatar
1 vote
2 answers
147 views

Is it possible to display Angular component using Angular Interpolation?

I have an Angular component that I depend on. This component has a getData method, then this method is called in the template of this component, and the result is displayed using Angular interpolation....
Andrii Hnatushchenko's user avatar
0 votes
1 answer
82 views

Groovy Yaml string interpolation with a list of maps

I am building a yaml string within Jenkins scripted pipeline that is parametrized. The problem is that I get error interpolating string with a variable that is a list of maps. I don't think I can use ...
Dmitry Tokarev's user avatar
0 votes
0 answers
33 views

Typescript Recursive String Interpolation

I'm working on a simple (but hopefully type-safe) system that represents timeSlots as strings. // example const t1 = "|mon::10:30|"; const t2 = "|fri::20:00|"; So far I have ...
Felipe Chernicharo's user avatar
0 votes
0 answers
22 views

invoke-webrequest fails with special characters [duplicate]

I am using a release pipeline to get a valid token, the client secret, and the user password via Azure Key Vault I am getting the client secret, and the user password. I did some tests and saw that ...
Bandit's user avatar
  • 497
1 vote
1 answer
497 views

How can I use a variable in a multiline string in Delphi?

Delphi 12 introduced multiline strings and I'm trying to figure out how it works, coming from a JavaScript background. There I can directly have variables in multiline strings such as: const myName = '...
Martin Kakhuis's user avatar
0 votes
1 answer
167 views

How to accept any variable type that can be used in SwiftUI Text view

I'm trying to create a reusable component for presenting a Swift collections OrderedSet into a SwiftUI List with delete, move and add handlers. I would like to be able to pass in an OrderedSet of any ...
thiezn's user avatar
  • 2,006

15 30 50 per page
1
2 3 4 5
75