Answer the question
In order to leave comments, you need to log in
Why is there no preloader with DOMContentLoaded?
project is fuzzy-bread.surge.sh
my main js file is index.js
import '@babel/polyfill';
import 'weather-icons/css/weather-icons.min.css';
import addHTMLstructure from './addHtml';
import showLanguage from './showLang';
import {
searchBy, search, feels, wind, humidity, latitude, longitude,
} from './wordsData';
import getUserLocation from './getLocation';
import setUpToDateLocationInfo from './setLocationInfo';
import addMap from './addMap';
import getForecast from './getForecast';
import setForecast from './setForecastInfo';
import setWeatherIcons from './setIcons';
import setDate from './setDate';
import setCurrTime from './setCurrTime';
import setImg from './setBackgroundImg';
import useGeocod from './useGeocoding';
import setSearchTime from './setSearchingTime';
import getTimeDifference from './getTimeDifference';
import setFahUnitFormat from './setFahrenheitUnitFormat';
import setCelUnitFormat from './setCelsiusUnitFormat';
import deletePreLoad from './delPreLoad';
require('./style.css');
require('./preLoaderStyle.css');
let currUnitsFormat = localStorage.getItem('units') || 'Celsius';
const currLanguage = 'en';
const currLangWords = {
searchBy: `${searchBy[currLanguage]}`,
search: `${search[currLanguage]}`,
feels: `${feels[currLanguage]}`,
wind: `${wind[currLanguage]}`,
humidity: `${humidity[currLanguage]}`,
latitude: `${latitude[currLanguage]}`,
longitude: `${longitude[currLanguage]}`,
};
addHTMLstructure(currLangWords);
setDate(currLanguage);
.......................
// Set Time
window.setInterval(setCurrTime, 3000, getTime);
document.addEventListener('DOMContentLoaded', deletePreLoad); ------- Почему это не работает??
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question