Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Dec 06 18:40
    cherifGsoul review_requested #5441
  • Dec 06 18:39
    cherifGsoul opened #5441
  • Dec 06 18:22

    cherifGsoul on update-infrastructure-page

    Update infrastructure page with… (compare)

  • Dec 06 18:14
    greenkeeper[bot] commented #5422
  • Dec 06 18:14

    greenkeeper[bot] on @feathersjs

    chore(package): update @feather… (compare)

  • Dec 06 18:11
    greenkeeper[bot] commented #5401
  • Dec 06 18:11

    greenkeeper[bot] on @feathersjs

    chore(package): update @feather… (compare)

  • Dec 04 22:03
    chasenlehara opened #5440
  • Dec 04 22:03
    chasenlehara labeled #5440
  • Dec 04 19:18
    cherifGsoul review_requested #5432
  • Dec 04 14:09
    m-ahmadi starred canjs/canjs
  • Dec 04 10:52
    ansyeow starred canjs/canjs
  • Dec 03 14:53
    matthewp commented #5439
  • Dec 03 14:30
    frank-dspeed opened #5439
  • Dec 02 18:13
    greenkeeper[bot] commented #5392
  • Dec 02 18:13

    greenkeeper[bot] on core-js-3.4.7

    chore(package): update core-js … (compare)

  • Dec 02 17:48
    greenkeeper[bot] commented #5392
  • Dec 02 17:48

    greenkeeper[bot] on core-js-3.4.6

    chore(package): update core-js … (compare)

  • Dec 02 15:38
    phillipskevin commented #5438
  • Dec 02 15:38
    phillipskevin closed #5438
Gregg Roemhildt
@roemhildtg
it looks like the generated html looks like this:
image.png
But in regular windows, chrome looks like this:
image.png
Kevin Phillips
@phillipskevin
ios safari you mean?
Gregg Roemhildt
@roemhildtg
Well, the same issue also appears in firefox, chrome, on iphone and ipad
Kevin Phillips
@phillipskevin
all browsers on ios use the same javascript engine
what does your template look like for the <option>s?
Gregg Roemhildt
@roemhildtg
<select {($value)}="value" class="form-select form-control" name="{{properties.name}}">
    {{#each properties.options}}
        <option value="{{value}}">{{label}}</option>
    {{/each}}
</select>
Kevin Phillips
@phillipskevin
ok, I don't see anything obvious. can you submit an issue also?
Gregg Roemhildt
@roemhildtg
Sure. It is related to the promise I mentioned. Providing an array list that is available immediately works.
Kevin Phillips
@phillipskevin
ok, how is the promise specified?
in your VM
Gregg Roemhildt
@roemhildtg
I'm passing an object to a component that has a .optionsPromise property
So I can pass either options or optionsPromise
canjs/canjs#3427
Frank Lemanschik
@frank-dspeed
https://www.npmjs.com/package/landscaper should be moved to a public accessible place so that some one can work more easy with it :)
AntonProkofyev
@AntonProkofyev

Hi guys, i have a question
i have simple connect like
let userConnection = connect( [url, constructor], { url: { getData: 'GET /user' } });
which returns someting like {name: 'Name'}

i have wm

let AppViewModel = DefineMap.extend( {    
    user: {
        get: function (lastSetValue, resolve) {
            userConnection .get().then(resolve);
        }
    }
});

let appVM = new AppViewModel({});

i'm using simple template like {{user.name}}. But when i get response i can see name but i can also see
Uncaught (in promise) TypeError: Cannot define property _instanceDefinitions, object is not extensible define-helpers.js:17.
Am i doing anything wrong with asynchronous getters? May be someone know why is this error appears?

Frank Lemanschik
@frank-dspeed
ithink its because user.name
is not a property
but my english is to bad to explain you that better and shorter simply wait for some one but it looks like your doing it wrong
AntonProkofyev
@AntonProkofyev
mmm i got response {name: 'Name'} from the server and i see Name on the page
Kevin Phillips
@phillipskevin
can you put a breakpoint in define-helpers and see what property is being set?
Frank Lemanschik
@frank-dspeed
i can't tell you more i never used it like you do
with the lastSetValue and resolve
i return the value and i get the value
Kevin Phillips
@phillipskevin
take a look at canjs/can-route#98
see if it is the same thing you are doing @AntonProkofyev
Frank Lemanschik
@frank-dspeed
@phillipskevin couldn't he directly return the promis and don't use resolve?
i think he could simply return userConnection.get() ?
Kevin Phillips
@phillipskevin
he could, but it would make the template more complicated
and not fix this problem
Frank Lemanschik
@frank-dspeed
why would that affect the template
i always return pormis
and get directly the value
Kevin Phillips
@phillipskevin
you have to do user.value.name in the template
AntonProkofyev
@AntonProkofyev
mmm let me check
Frank Lemanschik
@frank-dspeed
hmmm i always do this each stuff for user.value
Kevin Phillips
@phillipskevin
@AntonProkofyev the way your code is, user.name is fine
Frank Lemanschik
@frank-dspeed
and that works great
ah
Kevin Phillips
@phillipskevin
you can do it that way, @frank-dspeed
Frank Lemanschik
@frank-dspeed
then i have no value when i use his code style
interristing
Kevin Phillips
@phillipskevin
using the async getter with resolve, you don't have to do it that way
user is the value if you use resolve
Frank Lemanschik
@frank-dspeed
but then i can also do no waiting like if isResolved right?
because i only get the value
i understand the diffrence is getting a promis or a value i understand