We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'm converting the following PHP collections to JS variables:
JavaScript::put([ // <snip> 'launchVideos' => $missionObjects->where('subtype', MissionControlSubtype::LaunchVideo)->filter(function($item) { return $item->external_url != null; }), 'missionPatches' => $missionObjects->where('subtype', MissionControlSubtype::MissionPatch), 'pressKits' => $missionObjects->where('subtype', MissionControlSubtype::PressKit), 'cargoManifests' => $missionObjects->where('subtype', MissionControlSubtype::CargoManifest), 'pressConferences' => $missionObjects->where('subtype', MissionControlSubtype::PressConference)->filter(function($item) { return $item->external_url != null; }), 'featuredImages' => $missionObjects->where('subtype', MissionControlSubtype::Photo) ]);
Take particular note of featuredImages and missionPatches. They each have 1 member in the collection, once where'd.
featuredImages
missionPatches
where
Yet, the former is cast to a JS object, and the latter is cast to a JS array:
I am not doing any mutating on the front end, this is the raw output. Can anyone explain why this is occurring?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I'm converting the following PHP collections to JS variables:
Take particular note of
featuredImages
andmissionPatches
. They each have 1 member in the collection, oncewhere
'd.Yet, the former is cast to a JS object, and the latter is cast to a JS array:
I am not doing any mutating on the front end, this is the raw output. Can anyone explain why this is occurring?
The text was updated successfully, but these errors were encountered: