« first day (3420 days earlier)      last day (1511 days later) » 
00:00 - 17:0017:00 - 00:00

5:00 PM
I would very much like to help with the front end, but I'm pretty busy right now. Have some projects of my own. For sure sometime in the future.
Angulars community is larger isn't it?
 
@Unbreachable i don't have experience using it and I thought you were locked in to styles. I like custom stuff. But again, if a front end team emerges and decides on boostrap I have no problem with it.
@Unbreachable No problem! What ever you can contribute it fine. Even testing is helpful.
 
@JBis All the styles can be customized. In fact, it's kinda expected that you'd take the TWBS styles and make them your own
 
Hey how do I tell the difference between a `{ variableName: blahValue }` array, and a plain array `[ blahValue ]`

Lets just say I want to visualize folders/files, and I think arrays with actual groups would be best.

But I want to be able to tell the difference between a folder and a file.

A folder would be `var FileSystem = { folder: { nestedFolder: } }`

Files would be `var FileSystem = { folder: [ files ], folder2: [ files ] }
 
I understand. I used bootsrap a few times and it was great, but I agree with custom. Alright cooooool.
 
or perhaps it would be better like everything being a plain array with folders having some kind of distinction
 
5:07 PM
If you're trying to detect if it's an array, use the obj.isArray()
 
...
but
there are 2 different kinds of arrays
 
|| mdn isArray
 
{} and [], {} can support named values
[] just shows a collection of values
 
{} is not an array
 
5:11 PM
what is it then
Ive always kinda been confused by it
 
its an object
|| mdn object
 
everything is an object..
what kind of an object is it
 
||> typeof []
 
@JBis "object" Logged: ``
 
5:12 PM
boom
 
var a = {
 b : "Foo";
}
 
an array in js is an object with numeric keys
like ['a', 'b', 'c'] is just {0: 'a', 1: 'b', 2: 'c'}
 
||> ["Test","test1"].1
 
@JBis "SyntaxError: Unexpected number" Logged: ``
 
...
dont you mean [1]
 
5:14 PM
you cannot access if the variable isn't legit
:)
you need to [...] it
 
Ive stepped a bit out of my territory... Ima go work on that FakeDB API
It stores files as DataURLs in localStorage, and decodes them or can download them at any time
meaning you can emulate a database
however its not accessible on other pcs
so close
;-;
 
a word of advise: if you want to write API's, have a robust one
you aren't even checking every cases
 
but, what about if I dont know about every case
like Im not going to know every way something could happen by default
JS really puts the phrase "Expect the Unexpected" to the test.... sigh
 
2 hours ago, by TaylorS
  reqSetting() {
    this.settings.map(e => {
      return e + " - " + JSON.parse(localStorage.getItem(this.name + e));
    });
  }
that is just bad
 
Yeah, it didnt work.
 
5:17 PM
see
 
Thats why I went back to forEach
 
I even just have to read that
that .map is good
don't forEach it lol
 
But I dont even know how exactly to output the array with each having the name and value in each
like the foreach did
I tried asking yall how to do it
 
what was your forEach variant?
 
@Alex cool
 
5:19 PM
  reqSetting() {
    let set1 = [];
    this.settings.forEach(e => {
      let value = JSON.parse(localStorage.getItem(this.name + e));
      set1.push(e + " - " + value);
    });
    return set1;
  }
 
whats the benefit of using bootstrap tho? also you need to include jquery
 
forEach is easy to understand because you take in the value, and return it after applying changes to each
map just doesnt act how I expect it to
 
@JBis least effort towards cross-browser solution
that it's a hog is not a matter of importance.
 
It pretty much does every quirk for you, It deals with all the resizing and different browsers.
 
@TaylorS read mdn on .map? it has examples. That function means "transform this array to that array" while the function is the mapper (the transformer)
 
5:21 PM
map is really useful and easy to learn
 
but the fuck is settings variable?
 
I'd say if you don't want to put much time into the front end, then bootsrap is the way to go.
 
Is there anything wrong with using forEach?
 
i often use map + join over reduce
 
1 hour ago, by KarelG
@BenFortune fyi other actions besides "consuming" actions within forEach is just ugly IMO
@TaylorS ^
 
5:22 PM
this.settings is an array of every setting name
 
well use a map then
 
so your reasoning to call a couple lines of code bad and ask for a rewrite is because its "ugly"
 
JSON.parse(localStorage.getItem(this.name + e)); is not fool proof. Fix that first tho
handle a case where localStorage.getItem does not give something
(with other words: when it gives null)
 
karelG there cant be a situation where there isnt
also it returns null be default
That specific thing runs soon after the settings and their names have been setup, so the only way they could be "cleared" is if other code directly removed them
 
...
 
5:25 PM
About Foreach, Its standard notation, theres no bad practice crap about it online, its not deprecated.

It looks fine to me with some nice arrow expressions
 
||> let e = 'Taylor'; e + " - " + JSON.parse(localStorage.getItem('name' + e));
 
Invalid command! Did you mean: test, neat, list? Try help for a list of available commands..‍.‍.‍.‍.‍.‍.‍
 
...
 
Invalid command! Did you mean: 3, d, ^? Try help for a list of available commands..‍.‍.‍
 
||>
 
5:25 PM
@KarelG "ReferenceError: localStorage is not defined" Logged: ``
 
/Brug
 
okay
||> let e = 'Taylor'; let localStorage = {['name' + e]: null}; e + " - " + JSON.parse(localStorage.getItem('name' + e));
 
@KarelG "TypeError: localStorage.getItem is not a function" Logged: ``
 
ah fuck it
 
sorry its not in a browser
 
5:26 PM
yeah i forgot it
 
localstorage could probably be simulated tho
 
tried to simulate it
 
||> let e = 'Taylor'; let localStorage = {['name' + e]: null}; e + " - " + JSON.parse(localStorage['name' + e]);
 
@JBis "Taylor - null" Logged: ``
 
I am just showing Taylor that he can get that ^
that's not a robust API. That's a sign for me to bin it.
🚮
 
5:28 PM
For localstorage just make a variable that holds the data, and set custom protos to link to a class or variable object with the assorted commands that remove or add to that list
bot'd have to clear it once in a while though
 
@Unbreachable I am a bit hesitant . But maybe I'll try it.
I find I can do stuff better without a front end framework. Less code (more css than js) and it works just as well.
 
Yep programming is fun, many different way to do things. Use what works for you.
 
hmm, thanks for the suggestion
 
But bootsrap is easy, try it once
 
A little puzzle we had to solve recently: in JS, how can you tell when remote content has loaded into an iframe on your page?
 
5:37 PM
Anytime
 
The content is posted to the iframe via a form's TARGET property
But when has the content actually loaded?
 
6:04 PM
depends
 
Alex
 
can't you just use onload
|| mdn iFrame onload
 
Send data back and fourth via location hash
 
We used onload but then the challenge was: onload is fired once for the parent page itself being loaded. It's on the second time/subsequent times that it's loading remote content
 
6:08 PM
whats being loaded in the iframe?
like images and stuff? or a new page?
 
Nothing
 
> It's on the second time/subsequent times that it's loading remote content
 
That was the weird thing. The iframe is totally empty and it fires the onload
 
?
 
I know. Why?
 
6:09 PM
no
I am asking what you mean by that quote
@Alex if it has nothing to load its done loading
 
Oh, if we counted the times the onload handler was called, it was fired once for the parent page loading and then another time for the content of the iframe actually loading from the remote site
We needed to stop showing a spinner overlay when the remote content was loaded
So we ended up using a counter in the onload handler
 
are you doing iframe.onload?
or document.onload?
 
Yes
iframe.onload
But is it normal for an iframe to fire onload when the parent page renders it initially?
Anyway, that threw us a curve ball
And sorry my explanation was long winded and unclear :)
 
i don't think thats normal
 
6:37 PM
MCVE?
 
Got bored... Made fake database codepen.io/SkylerSpark/pen/BaNWPwz
 
@JBis If time allows here, among all the fires, will do
 
MCVE... isnt a thing anymore
This site is falling apart too much to care
Wasnt someone else working on a sort of "New SO"
 
6:59 PM
Yes me @TaylorS
 
7:12 PM
How long y'all think until browsers will error on http sites and only allow https sites by default?
I say 7 years. 2027.
 
I never thought of that. You really think http will be deprecated and https will be mandatory?
I will disagree and say never. At least not in our time.
Why would it anyway?
 
Browsers will have a security option to only allow https
 
Well, now that I think more of it, I guess that sounds kind of right.
 
It'll be off by default
 
7:28 PM
hmm wait so you think there will be an option for the clients to decide?
 
7:40 PM
@Unbreachable yes
@Unbreachable i think it will first be optional and then mandatory (except for localhost and you can disable if you want)
3 years for optional
@Unbreachable Prevent SSL Stripping and force web devs to have basic security
and since lets encrypt is free it won't be difficult
 
It being optional I agree with, but it being mandatory? Might take a while. I give it more than three years.
 
i said 7 for mandatory
but think about where we were 10 years ago
 
Our tech is advancing and so will our security. We are going to need more stringent security on the web, that is right.
You are right, it all moves so quickly.
 
Already we have web browsers defaulting to https, which breaks any site that is navigated to manually that doesn't support https.
for several of our older sites that sit unchanged without a cert, this is often a problem
 
Which browsers?
 
7:47 PM
@KevinB doesn't it try https and then go to http if https doesn't work?
 
no
lol
i wish
google chrome
 
huh?
 
ok, i got it backwards
it's not chrome doing it
it's google search
which... is just as bad imo
 
google search gives you http links
 
not for this example
 
7:49 PM
did your site once have https links so it thinks it supports it?
 
this site doesn't have an https version, never has. but google search gives it an https result
 
thats odd
 
it's been unchanged for... probably 6 years? maybe more?
we've never paid for a cert for it
 
HSTS somehow?
why not use lets encrypt its free?
 
because it only lasts 30 days?
 
7:51 PM
renewal should be automated anyway
 
that's work i don't have time for
 
ok i'll do it for you ready
 
On the iframe question: the empty iframe was being added dynamically on parent page load. Wonder if that would cause it trigger the initial onload
 
#!/bin/bash
certbot renew
add that to cron and your done
 
if only
 
7:53 PM
But seriously, thats an odd issue with google search
whats the site if you don't mind me asking?
 
i'd rather not
 
anyway, there is really no other solution to prevent ssl stripping that i can think of
 
for us the easier solution is going to be having cloudflare provide a cert for it
 
HSTS is the least scalable thing in the world
and it doesnt even protect against it on some requests
 
8:35 PM
 
9:22 PM
i'll be buying a new truck soon
 
Pickup?
 
yup
 
What're you looking at? I have a 2019 F150
 
probably f150, but i'm looking at rangers as well
 
Talked to one guy with one a while ago, paid ~$50,000 CAD for his Lariat Ranger, and I paid $59,000 for my Lariat F150
 
9:31 PM
yeah... that's why i'm strongly considering going ahead and getting an f150
 
And if you went with a 2019, better prices. Up here they're doing $20,000 of all F150s
 
priced pretty closely together. i don't really need more than a ranger, but... why not
 
Same thought process for me
 
yeah, there's a 2019 lariat f150 here for 50k$
new
the 2020 version is 56k iirc
 
do you ever use your pickup truck for the pickup truck features or mostly for looks
 
9:33 PM
occationally
my sport trac i've hauled with it... probably 7-8 times over 11 years
 
ah
 
granted, most of those cases we probably could have had stuff delivered
with the exception of helping my sis move 2 times
 
9:55 PM
@KevinB I'd think you could get that for $45k or less, depending on options
 
i don't recall the specifics
 
I used my old one more, off road or cleaning up construction debris, this one towed once and moved a few pallets
 
biggest thing i ever did with it was hauling off a fallen tree
 
nice
 
If have any questions about the new ones, let me know
 
9:58 PM
what's crazy imo is how the new ranger has a towing capacity of twice my sport trac
 
kevin, you (and others) might find interesting. How SA handles duplicate questions
 
Better frame I guess? I just find them small
 
main thing is i don't really see a whole lot of benefit for going with the f150 over the ranger. it's a little more roomy, bigger engine, but at the end of the day i don't need more than what i have, and the ranger already does that
and from a size perspective the ranger is closer in size to the sport trac (i've driven my dads 2019 f150 quite a bit)
 
I'd probably never sell mine, but I bet the resale value is higher on an F150 compared to the ranger
 
safe bet
 
10:05 PM
Do you think they would last a similar number of miles?
 
no idea
this sport trac has been reaaaly good in terms of not having any major problems, at 80k miles
 
Traded in my 05 F150 at 230k miles, with nothing major. Which is why I'm biased to the V8, simple but it works
 
 
1 hour later…
11:10 PM
does anyone know if the 'www' tld exists?
 
www.www.www
 
if not, could i borrow $250k and not pay it back?
 
i'd rather not
 
11:57 PM
Cya everyone o/
Off to rob a bank
 
I'll invest in this plan
$10
 
00:00 - 17:0017:00 - 00:00

« first day (3420 days earlier)      last day (1511 days later) »