Answer the question
In order to leave comments, you need to log in
What can be done on one page with JavaScript?
I'm just learning web development. I can safely make up an adaptive one-pager. But what about JS , it is required everywhere, but I just can’t understand in which places it needs to be applied. The carousel can also be done with CSS. Is it just for popups?
What can and should be done in LP using JavaScript?
Answer the question
In order to leave comments, you need to log in
Really stupid question.
For user, server and DOM interaction.
For example, using CSS and HTML, you can’t react to a button click in any way, you can’t send a request to the server, and you can’t add new styles after the page is loaded.
In short, what is needed for what:
HTML - for the base.
CSS is for styling.
JS - for everything else
Try to implement a toaster without a backend (for example on firebase) as a single line application. Or any other web application. And estimate what will be there in JS (essentially everything).
Table with values: sorting by fields, reaction to a click on a position with the output of additional information
According to the table, build a chart
By clicking, change to a chart of a different type
Firstly, one-pagers are not always LPs.
It can be a full-fledged site, with prices, product descriptions, etc., where everything will be loaded by ajax.
Well, try without JS to compose an LP like this gardenestudio.com.br/index.php
Everywhere the interactivity of the site is welcomed, but it is desirable to make it possible to work without js at all.
A real example: there is a website, more than 50% from phones (well, at least 25% in general from push-buttons) and losing them for the sake of purely interactivity is stupid
Facts (Google Analytics):
I strongly advise you to get rid of your idea that you "I can safely lay out a responsive one-pager" and continue to study web development further.
Anything, literally. If you want to do something, but run into the limitations of html5/css3, then you can do it with js. As I understand it, your question is "what to do", not "how to do it".
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question