« first day (3085 days earlier)      last day (1873 days later) » 
00:00 - 15:0015:00 - 00:00

12:06 AM
The best line I've ever read in docs: "If you pretend to use Java for coding..."
yep, I'll pretend
maybe they meant "intend"
 
 
3 hours later…
3:25 AM
Any ideas why nothing displays on Firefox? joshbrown.info/#contact
 
3:37 AM
Did you manually set z-indexes?
might also be opacities. I had a weird issue with degrees or something where in firefox it wouldn't work unless set to a certain number
 
@DavidKamer yes somewhere
 
try doing opacity: 0.01 instead of 0
oh, well z indexes might it it after all
oh wait
under fadeIn you have opacity: 0 !important;
 
yep opacity issue
@DavidKamer yep that's the issue, but it works everywhere else
 
how are you setting/overriding it?
remove !important and see if it still works everywhere
 
Gotta ask my self from a couple months ago...one sec
 
3:42 AM
odds are firefox interprets !important in a different order or something weird like that
 
@keyframes fade-in {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}
thats how
but apparently !important takes priority over animations in Firefox but not in other browsers (kinda agree with Firefox on this)
 
yeah, I just tested in the console
definitely the !important
that's why I never use !important
 
but
 
except when I do
 
@-webkit-keyframes fade-in {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1 !important;
    }
}
that doesnt work
 
3:44 AM
why are you setting it to important at all?
 
@DavidKamer I also don't however this is a case where I thought it was necessary.
Cause if elements have diff opacity setting fade-in animation should take precedence
 
yeah, I was always told to never use it and that there is always a better way to do it w/o using it. It's basically a goto in the modern web browser
@JBis I think you're over thinking it lol
 
Ah. Heres the reason: The contact page flickers without it.
 
just set it w/o important?
set it in the class that is already on it and then fade it
 
fixed flicker
one sec
 
3:47 AM
were you adding a class (or removing then adding) or something like that to make it flicker?
 
why using still vendor prefixes? especially webkit doesn't seem to be reasonable necessary
 
nope flicker fix didn't work
@jAndy In an attempt to fix Firefox I ran it through an automated vender prefixer 5 min ago. I can switch back if I want.
@DavidKamer I don't think so.
 
@JBis okay, are you setting style anywhere?
inline style
this worries me lol: .fadeIn_1, .fadeIn_2, .fadeIn_3, .fadeIn_5
 
@DavidKamer I know thats really bad but I have 0 clue how to do any other way lol
 
also try 0.01 instead of 0 if all else fails
@JBis wdu mean? if they're all doing the same thing just use one
 
3:51 AM
Ok I fixed it. Not exactly how I wanted but it looks fine,.
@DavidKamer they aren't, different delays.
 
.fadeIn_2 {
    -webkit-animation-delay: 500ms;
    animation-delay: 500ms;
}

.fadeIn_3 {
    -webkit-animation-delay: 1000ms;
    animation-delay: 1000ms;
}

.fadeIn_5 {
    -webkit-animation-delay: 2000ms;
    animation-delay: 2000ms;
}
unfortunately I can't do class="fadeIn(500)"
 
lol, CSS kind of sucks. I don't think you can pass parameters yet
 
Thanks for help
 
np, one thing is don't define more than the difference in separate classes. I can't remember if animation is a special case, but all other properties you could just use inline style
so if most of them were like 1000ms, just put that in the class
it would act as a default value
then use style to override it where you want
style={{animationDelay: '500ms'}} in jsx
 
3:55 AM
thought never use inline?
 
no, this would be a reason to use it
why make 5 classes that essentially do the same thing?
DRY
it's basically the same idea as passing a parameter to the class
inline style might be generally a bad idea, but this would be a good reason to use it IMO
 
fair enough. will switch over eventually
 
Rob
Depending on how many classes you've got... If you've just got the three, naming them fadein-slow, fadein and fadein-fast seems acceptable
 
I mean you don't always have to do it the "best" way, especially considering it's very subjective. You might very well run into an instructor/professor or whatever that tells you to never use inline. People always push an agenda when it comes to more than one way to do the same thing
 
prevents caching. gotta fix that too
@Rob another good idea
 
3:59 AM
@Rob would that work in inline styles?
I mean I assume it would
 
Rob
Not sure what you mean.. I'm suggesting giving the classes more descriptive names
 
yeah, I assume it's just like the default "blue" or whatever color
 
Rob
If there's only a couple, having standard speeds across the application seems desirable
 
ooohh
yeah, that's fair. I read an article by someone who does way more CSS than me and they were pretty edgy about everyone using classes for everything
 
gtg
thanks again for help
 
4:02 AM
adios, have a good one
@Rob with JSX you could just make it a variable though
there are tons of ways to accomplish that in your javascript and keep your css clean
and if you wanted it to default to 1s, it could be convenient.
idk, pick your poison I guess
 
4:14 AM
hi there, does es7 has annotation concept? If yes, how do I create one?
Something like
@template(path='xyz.html')
class MyComponent {}

I want to create a library that provides @template annotation
 
thanks @DavidKamer :)
 
5:12 AM
probably nsfw, but not sure. My judgement is pretty bad on the first watch tbh
 
 
3 hours later…
7:54 AM
I am looking for a web app technical test scenario, anyone has any idea ?
 
8:27 AM
const input = "a;b;'c;d'";

const expectedResult = ["a", "b", "'c;d'"];

function parse(input: string) {
  let inQuotes = false;
  return input.split(";").reduce((result: string[], part: string) => {
    if (inQuotes) {
      const last = result[result.length];
      result[result.length - 1] += ";" + part;
      if (part.endsWith("'")) {
        inQuotes = false;
      }
      return result;
    }

    if (part.startsWith("'")) {
      inQuotes = true;
    }

    return [...result, part];
  }, []);
@Neil in JS/TS ^
 
bleh, I think you could get something a lot simpler if you didn't initially split it
 
Maybe
 
assume that you have a proper datastructure, then can you not compare both as strings?
 
@KarelG What do you mean?
@Neil There, simpler
 
you tried to compare two objects as if both are equals to each other. I thought to just json.stringify it
 
8:31 AM
Got rid of the extra closure
 
yet that only works if there are no function objects within it
 
@KarelG At that point you should ask yourself what does it mean that they're equal to one another?
 
@MadaraUchiha that still splits the input by ;
 
@Neil Yeah, but I got rid of the extra closure
 
that all values in the object matches with the values from the other object
like .equals in java :D
 
8:33 AM
@KarelG Define "matches"
function arrayEqual(a, b) {
  if (!Array.isArray(a) || !Array.isArray(b)) { return false; }
  if (a.length !== a.length) { return false; }
  return a.every((aEl, i) => {
    const bEl = b[i];
    return Array.isArray(aEl) ? arrayEqual(aEl, bEl) : aEl === bEl;
  });
}
 
that for o1 and o2 ⇒ ∀ k in o1, o2 ⇒ o1[k] === o2[k]
 
Probably good enough for most cases
You can extend it for arrays.
But lodash almost assuredly has a better function.,
 
Hi, someone can help me with a easy question on Sequelize.js ORM?
 
It happens that I just copy over a lodash function body ( with reference! ) to my project
 
Would it be too rough to call "state managers" like vuex, redux & co. as overly complicated, semi-global objects?
 
8:53 AM
@jAndy Depends which
Redux is exactly a global object
MobX is no more a global object than a regular object might be global.
i.e. the globality is not inherent in MobX as it is in Redux.
 
well, same story with Vuex, with a similar overly complicated interface
I mean, it's kind of necessary to have such things, if you want to "share" data and state between objects/modules/components. But I'm slightly sick of all the bells and whistles which is going on about such things.
 
@jAndy Since when does sharing data and state implies that it needs to be global?
You just need to pass the same instance here and there, making it global is just the lesser way of achieving that effect.
 
well, most such called "state managers" use global objects. I'm no friend of that behaviour.
 
@jAndy Most popular libraries and frameworks use and abuse global variables.
 
if it was up to me, there was nothing global in any form or shape. There should be one integrated event dispatcher in ECMAscript, the rest is history to exchange data and state.
 
9:04 AM
I've got an easy question on Sequelize if someone knows the lib: stackoverflow.com/questions/55393016/…
 
Tom
9:50 AM
Hello everyone. Can I ask a question here about angular and redux?
or maybe there is another chatroom for these?
 
@Luggage wanna grab a beer in Baltimore ?
 
10:15 AM
will you stay in London, god dammit
 
@Tom those are javascript based frameworks. yes
#unfriendly @GNi33 :P
(don't take it serious please)
 
hi
 
hi atishr
 
@KarelG I'm just frustrated he gets to live in London :D
not frustrated because he does, but because I don't, just to clarify
 
heh, still not sure if it is a good location :P
brexit is nearby.... or not .... nobody knows
 
10:21 AM
not sure either. Love the city, but I never actually lived there
 
only delayed. Good for business 👍
been there multiple times for conferences
seems nice
 
until when is it delayed now anyways? until April 12th or did they push it further?
 
Tom
I need to do a blog with simple functionality with redux ngrx and angular. I have found how to show all blog posts, create a blog post with ngrx. But I don't know how to make one blog post printed. I understand that this has to be done with id. But I cannot find any info about that.And also I need to use localstorage. I have found github documentation. But it is not very comprehensive, so maybe you can help me with those?
 
@GNi33 currently that is the date to leave. They are still debating to delay it further (22 may I think). Depends of the votes in UK / EU parliaments.
 
isn't ngrx a collection of modules?
 
10:23 AM
I am not so familiar with ngrx.
 
oh well, who would've thougt that something like this could be complicated
It'll be interesting to see what happens with imports and exports in british and french harbors
there's not a real possibility for a test run of that, is there?
 
"no time" :)
my government has problems with that as well. The french customs has striked before because they need more people to handle the customs once Brexit occurs.
 
it'll most likely be a disaster for the first year or two, but I'm curious how they'll do in the long run
 
The petition for canceling brexit is gaining steam
 
I'm not getting my hopes up tbh
 
10:33 AM
I think it would be silly not to admit that perhaps public opinion has changed since then
So taking a second vote seems reasonable
 
"reasonable"
^ that might be a problem in this whole situation
a lot of stuff leading to this wasn't exactly reasonable
 
well that's what it boils down to, isn't it?
 
yeah, but reason is something people do not care about these days apparently
 
all you can go on is public opinion
if not, it's just a dictatorship
if the people say to leave, then the UK should leave.. though if public opinion changes.. well
 
and Brexit is a good example, for me at least, why you absolutely should not base everything on public opinion
but yeah, I agree with you. I just doubt that it'll come to a second referendum
and imagine if they'd vote leave again. The carnage
 
10:41 AM
it's not going to help the economy, that's for sure
Though it may even be better in the long run
it's hard to tell now what the effects will be in the long-term future
 
the whole Brexit thing (ridiculous term anyway) will kill German economics pretty much for good. England was the second biggest payer in the European Union... guess who is going to compensate
 
a lot of countries are being dragged along due to their debt, like spain and greece
This might pave the way for them to leave too
yeah, not going to be good for the EU overall
 
@jAndy yeah... no
you'll be fine
 
@Neil Why would they leave? The EU only benefits them
Leaving the union won't absolve them of their debts
 
@MadaraUchiha well, just like a bandaid, you have to rip it off fast
They could declare bankrupcy or whatever it is countries do
 
11:02 AM
Hey everybody, what would be the best way to turn this statement to a functional one?

if (cond)
return -1;
 
@Neil a referendum vote should be absolute
re-doing it is an insult to that principle
they have chosen to leave. Let it be.
they should take a referendum more serious next time.
@Traxstar what do you mean with that?
 
@Karel
 
@KarelG Joining the EU was a referendum vote too. Does that not mean that Brexit violets that principle by itself too?
 
@KarelG i mean in functional there i often read you should use like ternary operator and dont use the "normal" if
 
the first referendum got "handled"
the second is still not.
they can setup another referendum if they want to join eu back later
 
11:10 AM
@KarelG you understand what i mean . ?
 
@Traxstar that is a matter of use case tbh. If you want to know, there is a shortcut.
 
@KarelG what do you mean by there is a shortcut ?
 
assume that there is nothing after that statement, you can simply use return cond && -1
 
@Traxstar What do you return in the case of !cond?
@KarelG That's not equivalent.
 
it is
 
11:13 AM
It's not.
 
it does not give void. So
void is still falsy
 
function withIf(cond) {
  if (cond) { return -1; }
}

function withTernary(cond) {
  return cond && -1;
}

const cond = false;
console.log(withIf(cond) === withTernary(cond)); // false
 
if ! cond i run some other ternary like

function run(data){
if (cond)
return -1;

let p1 = fn1(data) ? 0.5 : 0;
let p2 = fn2(data) ? 0.5 : 0;

return p1 + p2;
}
 
You can't convert this to a ternary. Stick with the if.
 
@MadaraUchiha would there then be a better way to do that? I want to get sure to make this fully functional
 
11:17 AM
@Traxstar Who told you that if statements are not allowed in functional programming?
 
@MadaraUchiha Nobody tolds me that, but it feels like if am using ternary all the time it would be better to use it consistent all the way up and dont mix it, just because it don't suits directly. So i am itneresting in finding a bettter solution for this part
 
I hope that you don't nest your ternaries if you like to use that operator.
 
@Traxstar You use a ternary when things fit in one expression, and if statements when they don't.
It has nothing to do with functional vs otherwise.
 
@MadaraUchiha okay, well, do you might see a better solution for the run fnc i've given ? that maybe makes the code better in any way? or would you just let it be like that ?
 
It is good. Readable.
 
11:20 AM
@Traxstar For the example you've shown, that's how I'd write it.
 
use a minifier if you want to compress it.
 
No compression is not the point, it runs through webpack at the end :-D i just mind in fact of reading
@MadaraUchiha so you would let it be like it its ? :-D
 
@Traxstar 👍 good call.
@Traxstar I'd probably use const and not let if you don't change p1 or p2 after setting them
 
@MadaraUchiha Thanks for your help! Yeah that would make sense
going for fully immutable at the moment
as far as i can :-D
@MadaraUchiha what about this ? pastebin.com/tU1azEQL
 
fntest = ([current, next]): data => {
 
11:25 AM
@KarelG that'll teach'em
 
@MadaraUchiha is this some kind of destructuring?
 
@Traxstar It is destructuring
 
Seems silly to follow the "referendum is law" on a matter of principle
 
Thats Awesome! So there would be one last point that i dont like of that fntest

It's the fact that i modify the existsting current obj
 
@Neil Deciding if/when to hold another vote on a referendum is a hard problem. You can't just keep voting until they get the right answer.
 
11:28 AM
@KendallFrey This isn't some philosophical debate where we have to worry about holding votes until the world ends
It's very practical matter of change of public opinion
 
it is not?
 
Before making the plunge, just make sure the people still want it
 
could be that those that wants to leave did not made noise so far ...
you do not know that. It is true that the vote is really close. 51% ?
it is 51.9%
 
@MadaraUchiha would there be a better way to run this without modifing the passed objects ?
 
Following through with it when it isn't what is best for the UK nor is it what the people want on a basis of "well.. it IS a referendum.." is ridiculous at best
 
11:30 AM
.
 
@Neil How do you determine what the people want until you actually hold another vote?
 
@KendallFrey That's sort of the whole point, isn't it? There are strong indications that brexit is no longer supported.. the vote makes it official and without a doubt
And before you argue that it was official and without a doubt before, I agree with you, but time has passed
 
OK, but what should be the criteria for retaking a vote?
 
fntest = ([current, next]) => {
  if (has('attr', next)) {
    current.attributes = {...current.attributes, [attr]: next.attributes.attr};
  }
  return current;
};
Probably, something like that.
 
Again, you're getting into details which are rather impractical
 
11:34 AM
I could certainly see that this situation falls on the re-vote side, but you kind of need a policy for this or you're vulnerable to corruption
 
News sources: AI is super dangerous and everyones gonna die
Paypal:
in Java, 45 mins ago, by Hans1984
user image
 
@MadaraUchiha what does that .... means?
 
@KendallFrey Require a 2/3 majority for referendums.
@Traxstar Object spread operator.
 
If alien pod people start taking over great britain and replacing people, and these people all really want to tend to attack people with a knife in hand, you do not need legislation asking for a swift trial to ensure that the pod people can be handled differently in the court of law with respect to, say, a normal mass-murdering joe
 
@MadaraUchiha What does this do or effects?
 
11:35 AM
@MadaraUchiha That merely shifts the issue, doesn't solve it
 
To focus on law in such instances is ridiculous and impractical
 
@KendallFrey If you get a 2/3 majority, it's unlikely that you need a revote because vote only passes with a strong consensus.
 
Would a re-vote then be 2/3 or 1/2?
 
public opinion has changed.. how much has it changed? lets hold a vote to find out..
Will we have another public vote to determine if public opinion has changed after 4 days? No.
 
2/3, else it defeats the purpose.
 
11:36 AM
Simple as that
 
@MadaraUchiha Making it 2/3 defeats the purpose as well, because you have the exact same problem if the vote is fluctuating between 60% and 70% instead of 45% and 55%
The more I think about it, 1/2 majority to overturn a 2/3 majority might actually be a usable system
Though perhaps the ratios are too far apart
3/5 - 1/2 maybe
 
again, non-important details.. you might as well statistically prove within several standard deviations that the vote isn't likely to change within a margin of error of 0.1%
at a certain point it's just ridiculous and impractical
 
@KendallFrey Revote needs 5% stronger consensus from first vote to take effect.
 
Making reasonable assumptions isn't stepping on anyone's toes
Assuming after a revote that 1/6th of the population isn't going to just up and change their mind is not a horrible assumption
assuming it is done within days of making a final decision
 
@MadaraUchiha That suffers from the problem of forcing a re-vote from someone who doesn't support the result, because that makes it even less likely to go through
Either way I suppose you need a minimum waiting period for a re-vote
 
11:42 AM
How about this, look at it in terms of pros and cons. What is the con in taking a revote save for the costs for holding a vote?
 
@Neil If not careful, I could delay the decision for years.
 
Is the cost of holding a vote too high with respect to leaving the EU? I would argue not
 
With more revotes, and more appeals etc etc
 
so you're trying to tell me that the UK will turn into a gigantic ant death spiral where it can't seem to come to a conclusion at all and bury itself in debt?
All because of one revote? Bit of a stretch isn't it?
 
@Neil We vote, I disagree, call for a revote, you disagree, call for a rerevote, etc
 
11:46 AM
@MadaraUchiha 2/3rds vote in favor of stopping brexit... who disagrees? the 1/3rd?
 
Yeah, I'll claim that public opinion has shiften, and now I expect there to be a strong majority in my favor.
@KendallFrey Wait, no
You need 2/3 the other way to revoke the decision
 
If 60% voted in favor of brexit initially and only 30% vote in favor of it now, then public opinion has shifted 30% in several months.. it's hard to make a claim that over a couple days it will have shifted again by a similar margin
 
That seems excessive
I doubt a brexit re-vote would get a 2/3 stay
 
maybe not, but at least it's concluded (at least for most people)
I would be happy knowing that though I would have wanted UK to stay in EU, a last ditch effort was made to determine if it was truly something that the people wanted
most people aren't going to riot what the majority have decided, at least not unless most people have changed their minds in the meantime
There doesn't seem to me a good argument for leaving brexit other than "Well done is done"
 
11:51 AM
@MadaraUchiha i am trying to implement the spread operator but stuck a bit. in first object i got a nested attribut that sould be placed in the second one, also as a nested prop - how would this work using the spread operator ?
 
if it means fudging things a bit, so be it. The law is a reflection of what the people ultimately want to maintain order. If the law goes against order, then it is no longer doing what it is supposed to
so change the law
 
@MadaraUchiha already got it! :-D
 
You still haven't solved the problem of when it's appropriate to hold a referendum
 
@KendallFrey Let's call it, if you have a nontrivial N number of signatures.
 
Yeah, but that means any close vote can be retaken infinitely as long as you have enough people on either side willing to sign
 
12:13 PM
@KendallFrey sure, and assuming you can get that many people to switch votes in the time it takes to commit to the decision
 
@KarelG If you have some experience with Dojo, I will be very grateful if you help me with a list of data.
 
"a list of data"? :P
 
@KarelG a grid
 
@Neil You don't need to actually have people vote differently, you just need to hold votes repeatedly to "filibuster" the result
 
used dojo.grid.datagrid or something?
 
12:16 PM
@KarelG look at this example: codesandbox.io/s/8zro6m4kj9
@KarelG I have been trying to use that example for days and I can not. Dojo is the most disgusting thing I've ever seen in my life. I can not find documentation (only version 1.X). I need to do it with the 2.x
 
@KendallFrey you can't get a vote if you don't have the support
 
22 mins ago, by Kendall Frey
Yeah, but that means any close vote can be retaken infinitely as long as you have enough people on either side willing to sign
You almost always have support from the losing side. There's almost always a losing side.
 
if they have enough people to vote the contrary, then the vote to cancel brexit won't succeed
it'd be silly to hold a vote with millions of people, and then let 100 guys who didn't like the result hold another vote
 
I am ashamed to ask this question
 
@Carlos ya ok. I have a lunch meeting now. I just checked the repo and not sure if this is useful
 
12:20 PM
but how can I resolve the return value?
 
@Suisse Now you have my interest :)
 
async function getBase64FromImageUrl(url) {
    var img = new Image();

    img.setAttribute('crossOrigin', 'anonymous');

    img.onload = async function () {
        var canvas = document.createElement("canvas");
        canvas.width =this.width;
        canvas.height =this.height;

        var ctx = canvas.getContext("2d");
        ctx.drawImage(this, 0, 0);

        var dataURL = canvas.toDataURL("image/png");

        return (dataURL.replace(/^data:image\/(png|jpg);base64,/, ""));
    };

    img.src = url;
img.onload ... how to get the return value of this callback
 
wait ...
 
await
 
what are you doing lol
 
12:21 PM
lol yeah it is a little odd
 
ok ok
function getBase64FromImageUrl(url) {
    var img = new Image();

    img.setAttribute('crossOrigin', 'anonymous');

    img.onload = function () {
        var canvas = document.createElement("canvas");
        canvas.width =this.width;
        canvas.height =this.height;

        var ctx = canvas.getContext("2d");
        ctx.drawImage(this, 0, 0);
        var dataURL = canvas.toDataURL("image/png");
        console.log(dataURL.replace(/^data:image\/(png|jpg);base64,/, ""));
    };
    img.src = url;
 
what you probably mean to do is in the onload function, you locate and set the src attribute for your image..
 
how can I access the value of dataURL outside of the callback
 
the image should be on the page, or onload will never get called to begin with
you can't
 
@Neil the image is not on the page.. I pass the url from where ever

it loads and when it is loaded I want to geht its dataURL
 
12:24 PM
the code inside is getting executed in a moment different than the code outside
 
yes yes I know that
but how to await for the inside code
 
@KarelG Ok, we will talk later. Have a nice day.
 
I want to talk NOW! ok karl
karl that kills people
 
@Suisse Try moving the img.src = url; line inside the onload at the end
it may be as simple as that
 
hehe @Neil.. no look thats a diffrent thing
in that function you pass the url of an image
after that it creates a new Image() and sets its src from the passed url
and than asynchron sometimes later the onload is triggered
and when that is triggered the dataURL is readed from a temporary created canvas
I don't want to see the image on my html page or so
I need to get the dataURL from any image
 
12:56 PM
I am missing something important
if you get the image via that .src attribute
why are you toying with the canvas?
and what do you want to do with the dataURL?
 
 
1 hour later…
2:04 PM
I have a Vue object where, in the mounted function I set up a listener for a specific event (triggered by form elements elsewhere on the page, outside the Vue object's control element). I have a particular computed property in the Vue object that always evaluates as soon as the event comes in, but before the event handler runs.
The event handler assigns some values that the computed property is dependent on, but the property gets evaluated before they are assigned, so it ends up getting called twice, and I don't understand why. I have other computed properties that aren't getting called at all.
The call stack shows nothing but vue.js code running up until the computed property is evaluated.
 
2:17 PM
My team in Minneapolis, MN is still looking for a Sr Front End Engineer. Ping me for more information!
 
U mean that a computed property should be updated in the event handler but it looks like it get updated just before the function get called ?
@Hypersapien And updated a second time when the handler runs its code ?
 
Yes
 
And if you put a console.log in the event handler, does it also get called twice ?
It could sounds like the event was binding 2 times
 
I wasn't using console.log, I was using breakpoints.
Let me check that. Hold on
 
huh, an existing websocket still works when offline is ticked in the devtools
 
2:24 PM
I put a breakpoint on the line where the listener is being created. When I reloaded the page it only got hit once. Is that what you mean?
 
What kind of event is it ?
 
oh damn did I miss some drama
 
I have another Vue object on the page that controls the search bar. The search bar is passing search information to the main part of the page containing search parameters.
And i think I may have figured out what's going on
I think when I pass the default search object when the page first loads, I'm getting a reference to the one in the search Vue, and when the search Vue makes changes to its object it's registering the changes in the main Vue.
Although that doesn't make sense because the computed property isn't referencing the search object.
In fact I have another computed property that is referencing the incoming values and isn't getting called until they're assigned.
 
2:40 PM
Hm
 
But apparently stringifying and re-parsing the search parameter object worked. And I have no idea why.
 
As computed are cached and only recomputed when one of their reactive dependency change, you could maybe watch() for those change, and maybe use a console.trace() to understand when/where those change are applied
I think that JSON.parse(JSON.stringify()) will create a real copy of your object, not by reference, so you might be right about you tought
 
Actually, the computed property that references the search object is referenced by the property that was getting called. Is Vue smart enough to string computed properties long like that?
That might be it
Ok, brand new question. Not about Vue.
 
Can anyone tell me how I can build/import a (local) library when I "ng test" my application? It cannot find the references while testing, while "ng serve" works just fine
 
If I have a process that takes a noticeable amount of time to run, and I want to make a change to the DOM before it starts (specifically throwing up a 'loading' spinner with a semitransparent full-screen background) how can I make that change without the process eating up all the CPU time and not letting the change become visible until after it finishes?
Is there a way to force an immediate redraw of the page?
 
2:58 PM
I didn't really understood what you meant by: letting the change become visible until after it finishes?
You'd like to have a smooth animation and run an heavy process at the same time ? That's it ?
 
00:00 - 15:0015:00 - 00:00

« first day (3085 days earlier)      last day (1873 days later) »