These are chat archives for FreeCodeCamp/HelpFrontEnd

11th
Jun 2018
Zack Adams
@mindforcode
Jun 11 2018 00:12
Hey guys
Anyone around?
Corey Lewis
@cursiv3
Jun 11 2018 00:16
hello
Zack Adams
@mindforcode
Jun 11 2018 00:17
Hey Corey!
I solved my problem, just being dumb :)
Austin Jess
@ajess33
Jun 11 2018 00:49
I started my react app with create-react-app and when I use const in I get an error saying: 'const' is only available in .ts files.
Anyone know how to fix this?
niknows
@niknows
Jun 11 2018 01:28
Hello there, what's up?
Corey Lewis
@cursiv3
Jun 11 2018 01:44
Austin
@ajess33 do you have a linter in your editor?
Austin Jess
@ajess33
Jun 11 2018 01:48
@cursiv3 yeah I have eslint integrated into my vscode
Corey Lewis
@cursiv3
Jun 11 2018 03:10
my guess is it's a linter issue, if you're using create-react-app there shouldn't be any problems using const
Claudio Restifo
@Marmiz
Jun 11 2018 04:25
@ajess33 have you just updated to the newer version of VSCode?
Happens to me this morning as well that I have some random linting from TS in my absolutely TS-free project :smiley:
Ehsan Shadmehri
@ehsansh
Jun 11 2018 05:39
Hi, What is the best practice to load multiple audio files in one page? I ask because sending many server requests is not good. I thought to convert all audio files into one single file but I do not know how to change it to the first status.
HammadUmerFarooq
@HammadUmerFarooq
Jun 11 2018 07:03
Hey Hi Every one
Norvin Burrus
@ndburrus
Jun 11 2018 10:16
@ehsansh this may be useful :sparkles:
Ali Bulut
@ali27001
Jun 11 2018 12:20
https://files.gitter.im/angular/angular-2-ionic-2/kzHa/image.png Select is not working properly on iOS devices when I use cordova. do not click. How do I solve this
richRocksCodeBlocks
@richRocksCodeBlocks
Jun 11 2018 13:51
@buiphuking If you are working with Larval I recommend using valet for your local development. https://laravel.com/docs/5.6/valet
include*engine
@newtothat
Jun 11 2018 16:24
yesterday i installed a game called 'second life' and when windows asks you if you want the software to make change in this computer i said yes so it completely changed my computer and it didnt work a day .Now i see everything big like really huge
i resized it with ctrl - + and still not the same as it was before
and it made change not only visually but to files as well some of them I can't find
anyone knows how to fix this? or have someone experienced such thing
Brad
@bradtaniguchi
Jun 11 2018 16:59
@newtothat Sounds like you turned on some accessibility options for zoom or installed malware. When you install software usually it prompts you for security access (isn't JUST second life) but the results are usually never malicious if your installed legit software
Abdullah-Al-Zubair
@a2-zubair
Jun 11 2018 17:17
Hello guys, Need your help. I'm stuck in "Sass: Create Reusable CSS with Mixins" topic. All task is pass except the last one : "Your code should call the border-radius mixin using the @include keyword, setting it to 15px."
Now i don't understand where i'm doing wrong? can you help me? here is my code
<style type='text/sass'>
  @mixin border-radius($radius){
    -webkit-border-radius: $radius;
    -moz-border-radius: $radius;
    -ms-border-radius: $radius;
    border-radius: $radius;
  }


  #awesome {
    width: 150px;
    height: 150px;
    background-color: green;
    @include border-radius:15px;

  }
</style>

<div id="awesome"></div>
Mois├ęs Man
@moigithub
Jun 11 2018 17:29
wrap the parameter u pass to mixin on ( ) parenthesis @a2-zubair
ie @include myMixin(value )
Corey Lewis
@cursiv3
Jun 11 2018 18:03
anyone here know a bit about security? Namely if the whole "React is XSS safe by default" is true?
Abdullah-Al-Zubair
@a2-zubair
Jun 11 2018 18:05
@moigithub thanks man.
include*engine
@newtothat
Jun 11 2018 18:31
@bradtaniguchi do i need an antivirus?
i know what case sensitivity means in js vars but i don't know what Quincy meant here

// Declarations
var someVariable;
var properCamelCase;
var titleCaseOver;

// Assignments
studLyCapVaR = 10;
propelCamelCase = "A String";
titleCaseOver = 9000;

Brad
@bradtaniguchi
Jun 11 2018 18:33
@newtothat I don't think so, unless you start seeing clearly virus like stuff. Again Id look into your accessibility settings. Google it if your not sure where they are.
include*engine
@newtothat
Jun 11 2018 18:34
Brad it's like when you teach 1st grades kid with a big pics.my laptop is like that right now
hellhound123
@hellhound123
Jun 11 2018 18:52
Hey guys, I have this grid of images, that I've set up using flexbox. I'd like it to be centered, but also keep control of how much space is between the images. I've tried margin 0 auto but that keeps an amount of space between the grids that I can't change. The container already has a margin 0 auto attribute as well. Here's the code
.gridsection {
    margin: 0 auto; /*Centers section*/
    max-width: 75%; /*Specifies how wide section is on page*/
    text-align: center;
    display: flex; /*Sets container to flexible for flexbox use*/
    flex-flow: row wrap; /*Combines flex-direction and flex-wrap properties, row stacks left to right, wrap allows to wrap when needed*/
    align-items: stretch; /*Items stretch to fill container*/
}

.timeline-img{
    position: relative;
/*    margin: 0 auto; */
  padding: 8px;
    vertical-align: top;
    height: 300px;
    width: 300px;
    overflow: hidden;
}
image.png
As you can see, it's off center
hellhound123
@hellhound123
Jun 11 2018 18:59
image.png
I'd like it centered like it is here, but still be able to control that column spacing that's wider than the rows
Gulsvi
@gulsvi
Jun 11 2018 19:03
@hellhound123 Add justify-content: center; to your .gridsection class.
Also, since you're using bootstrap, you could reduce a lot of your CSS by using the built in bootstrap flexbox utilities instead
hellhound123
@hellhound123
Jun 11 2018 19:04
I've actually been coding this locally without bootstrap
Just copying it to codepen for sharing purposes
Gulsvi
@gulsvi
Jun 11 2018 19:05
Ahh, in your codepen settings you have bootstrap added in the CSS section
hellhound123
@hellhound123
Jun 11 2018 19:05
Probably just a holdover from the initial FCC setup!
How would I control the width of the colum? I'm trying padding, but that's not working, it only affects top and bottom, left and right have no effect
include*engine
@newtothat
Jun 11 2018 19:08
why people think that if microsoft owns github itll ruin it??
i have nothing to lose of couse because i was about to learn github but still don't know it
Brad
@bradtaniguchi
Jun 11 2018 19:10
@newtothat The main thing is microsoft is a big corporation, and now they can look into private repos, which a lot of other companies own, and see what you got (technically
include*engine
@newtothat
Jun 11 2018 19:11
i see
then it's a big problem
Gulsvi
@gulsvi
Jun 11 2018 19:12
That's b.s. you think Amazon is looking at everyone's AWS code? They wouldn't succeed if the were.
err. code on AWS servers
How would Azure have lasted this long if Microsoft was peeking at everyone's enterprise server code?
@hellhound123 Sorry, didn't see your followup question. You have them all set up as 300x300 right now. Ideally, since it looks like you want to use flexbox, set up flex columns. https://css-tricks.com/dont-overthink-flexbox-grids/
include*engine
@newtothat
Jun 11 2018 19:14
@bradtaniguchi so what happens them?
then*
many developers planning to migrate somewhere else ?
Gulsvi
@gulsvi
Jun 11 2018 19:18
It isn't going to happen... Microsoft hosts classified code for governments around the world. Even if they decided to take some private code, package it up in a closed-source project, they get audited all the time. That's too big of a risk to lose their $7 billion investment in github.
Tom
@moT01
Jun 11 2018 19:18
I really doubt that microsoft will be looking into private repos - if it's found out they're doing that, developers will probly leave in droves and there will no money to make from their acquisition - besides microsoft must have some of the best engineers in the world - why would they need to - my opinion
Gulsvi
@gulsvi
Jun 11 2018 19:19
From what I'm reading, the only credible concern is that Microsoft will make github into some terrible UI experience like they've done with Office
But....that's a legacy fear. They've hit the ball out of the park with VS Code and personally, I think they're going to do the same with Github improvements
Brad
@bradtaniguchi
Jun 11 2018 19:22
It probably is BS, but people are people
Kudzu
@czhower
Jun 11 2018 19:22
Im trying to be optimistic, but I hope they do better with it than they did Skype or Nokia (and I'm ex Microsoft myself)
Brad
@bradtaniguchi
Jun 11 2018 19:23
Gitlab is already saying they are seeing exponentially more exports from github haha. I personally don
t believe Microsoft will do anything myself, but I'm not other people
Kudzu
@czhower
Jun 11 2018 19:23
github falls under the os/dev side of MS though, not the business side like Nokia and Skype. DevDiv has a LOT better record in these areas.
Brad
@bradtaniguchi
Jun 11 2018 19:25
The main thing with Microsoft, which is smart, is they are walking away from just focusing on Windows, since they know that isn't the future. Stuff like VSCode works on all platforms. Same will go for github
include*engine
@newtothat
Jun 11 2018 19:31
what about git
they gonna own it too
?
what are alternatives
i mean do companies use it? im asking for future jobs apportunities
Kudzu
@czhower
Jun 11 2018 19:32
git is open source, MS does not own it.
include*engine
@newtothat
Jun 11 2018 19:32
we will be learning new technologies?
Brad
@bradtaniguchi
Jun 11 2018 19:36
I mean you could walk backwards, and go learn mercurial or subversion, (other source control tools) but I wouldn't advise it
include*engine
@newtothat
Jun 11 2018 19:38
@bradtaniguchi from what you told me i got that many small companies uses github and it is required for disntance working
using git and github
as you know i am a newbie so i just wonder if companies going to change the way they were worked with git and github?
Kudzu
@czhower
Jun 11 2018 19:39
SVN is very good, in fact many devs prefer it to git. Git is more popular overall mainly because of github itself, not because git or SVN are better than each other.
We use git for open source, svn for commercial and thats by team choice.
(git, because of github)
include*engine
@newtothat
Jun 11 2018 19:40
in turkey a lot of companies ask for git and github
Kudzu
@czhower
Jun 11 2018 19:40
There is also bitbucket, but really I think ppl are panicing over nothing especially at this point.
include*engine
@newtothat
Jun 11 2018 19:41
i applied twice for job and was rejected lol they said that i have to learn a lot
so I decided to learn a backend before I apply for another job
and improve front-end skills as well
Corey Lewis
@cursiv3
Jun 11 2018 19:57
@czhower I agree, I think everyone has this evil money grubbing corporate view of Microsoft due to their history when lately they've been much more of a startup attitude, like "let's build cool stuff for everyone and figure out how to make some money later"
Brad
@bradtaniguchi
Jun 11 2018 20:02
@newtothat Just make sure your skills with the fundamental aspects of the language(s) your learning are good.
Its no good to know the basics of 5 different stacks, if you have bad fundamentals
Roman Macak
@DrMacak
Jun 11 2018 20:25
Hi everyone!
Brad
@bradtaniguchi
Jun 11 2018 20:26
@DrMacak Hello
Roman Macak
@DrMacak
Jun 11 2018 20:26
Im working on little project of mine and looking for someone to help me with front end. I know quite well JS/PHP but suck at CSS/UI design
So now I have quite well working app, but it looks ugly
@bradtaniguchi Hi!
Im using bootstrap + font awsome
So if someone is interesting the improve their skill I would appreciate help
Claudia Danciu
@ClaudiaDanciu
Jun 11 2018 20:29
if I can help let me know
@DrMacak
Roman Macak
@DrMacak
Jun 11 2018 20:30
@ClaudiaDanciu Nice! Could you show me some stuff you have done?
Kudzu
@czhower
Jun 11 2018 20:45
Brad
@bradtaniguchi
Jun 11 2018 20:46
Id like to help, but I'm terrible at UI/UX haha
Kudzu
@czhower
Jun 11 2018 20:48
Many devs suck at UX and its why design and dev are discrete fields.
Roman Macak
@DrMacak
Jun 11 2018 20:49
I personally just hate CSS not UX...
How I see the CSS is all just pile of hack to put stuff together, when you usually want just simple thing like put something on center etc.
Kudzu
@czhower
Jun 11 2018 20:52
yes, it very much is that.
Its even worse when you have to integrate with someone elses pile of CSS.
include*engine
@newtothat
Jun 11 2018 20:52
what is the difference between order in making a website for a desktop first then for tablet and then for mobiles? there will be any troubles with media quiries?
Roman Macak
@DrMacak
Jun 11 2018 20:53
gg bye all!
Brad
@bradtaniguchi
Jun 11 2018 20:54
c Ya
Christopher McCormack
@cmccormack
Jun 11 2018 21:04
@newtothat If you plan on making it work on all platforms, you should build it from the ground up with those sizes in mind. Plan your layout so you can modify the CSS of the sections using media queries.
@newtothat CSS frameworks tend to have responsiveness in mind in their Grid layouts. They have media queries already defined based on the most common viewports for different devices
Brad
@bradtaniguchi
Jun 11 2018 21:13
TDD is my new fav, too bad it makes me work far slower, but hell no bugs yo!
Corey Lewis
@cursiv3
Jun 11 2018 21:24
@bradtaniguchi TDD is amazing but man does it take discipline, so hard to get myself to write tests first
Brad
@bradtaniguchi
Jun 11 2018 21:29
I'm working on some things that REALLY need it, and already set everything up with table driven tests, over 100 tests for this area of code haha. (Its like a dynamic rule engine, so I test most of the possible rules and combos)
Jacob Colborn
@jcolborn-dropdeadgames
Jun 11 2018 21:41
I've been thinking about researching TDD to use with my new project, but it seems like such a monster haha
Brad
@bradtaniguchi
Jun 11 2018 21:45
Im not purist, the main thing is writing tests before your write your code (the purists say do it WHILE you write the code) and design your code to be testable. (keep functions small, simple and clear)
everything else seems like "fluff", at least to me
TonyRednil
@TonyRednil
Jun 11 2018 23:22
Hey guys, I was wondering, is it possible to view all the potential outputs of an api? I'm trying to view all of these so I can set my weather backgrounds properly
Brad
@bradtaniguchi
Jun 11 2018 23:23
@TonyRednil Not that I know of, youd have to be able to know the inner workers of the API to know whats available.
TonyRednil
@TonyRednil
Jun 11 2018 23:29
@bradtaniguchi so how would you suggest to code it so that the background image changes dependent on the weather conditions? Would you say if(json.weather[0].main == cloudy) {document.getElementById("background").src=url("cloudy.jpeg")?
Brad
@bradtaniguchi
Jun 11 2018 23:56
@TonyRednil Yea, Id look into the documentation for the API to see the possible return results.