Git Product home page Git Product logo

Comments (4)

VadimDez avatar VadimDez commented on July 21, 2024

i can't see what ngx-order-pipe has to do with this. It seems like it's your own code that triggers the issue.

from ngx-order-pipe.

itsnotme01 avatar itsnotme01 commented on July 21, 2024

Hello,
It seems I have the same trouble when I try to do this kind of things:

<select id="createMailboxLanguageDropDown" class="form-control"
     [(ngModel)]="fileContent.MailboxLanguage" name="createMailboxLanguageDropDown">
    <option *ngFor="let language of languages | orderBy: language : false : true [value]="language">{{language}}</option>
</select>

In this case the order works but the production mode build (ng build --prod) fail with the same error as @otmane-ma

If I try to add a property languageOrder or language with the value 'language' in my component the order does not work.

Do you have an hint on how to directly sort an array of string in the html?

from ngx-order-pipe.

itsnotme01 avatar itsnotme01 commented on July 21, 2024

Hello again,
After some tests I found a solution for my case (sorting an array of string in an ngFor directly in the html), I just need to orderBy an empty string like this:

<select id="createMailboxLanguageDropDown" class="form-control"
    [(ngModel)]="fileContent.MailboxLanguage" name="createMailboxLanguageDropDown">
    <option *ngFor="let language of languages | orderBy: '' : false : true [value]="language"{{language}}</option>
</select>

Sorry for the inconvenience.

from ngx-order-pipe.

stale avatar stale commented on July 21, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from ngx-order-pipe.

Related Issues (20)

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.