File: src/webdav.ts

Recommend this page to a friend!
  Classes of Dom Hastings   JS Webdav Client   src/webdav.ts   Download  
File: src/webdav.ts
Role: Example script
Content type: text/plain
Description: Example script
Class: JS Webdav Client
Access files of a Webdav server
Author: By
Last change:
Date: 6 months ago
Size: 1,363 bytes
 

Contents

Class file image Download
import './style.scss'; import Container from './components/Container'; import DAV from './lib/DAV'; import Footer from './components/Footer'; import Header from './components/Header'; import LanguageDetector from 'i18next-browser-languagedetector'; import List from './components/List'; import State from './lib/State'; import UI from './components/UI'; import de from '../translations/de.json'; import en from '../translations/en.json'; import pt from '../translations/pt.json'; import { use } from 'i18next'; import Tree from './components/Tree/Tree'; import WebDAV from './components/Tree/WebDAV'; import PlainObject from './components/Tree/PlainObject'; use(LanguageDetector) .init({ detection: { caches: [], }, fallbackLng: 'en', resources: { de, en, pt, }, }) .then((): void => { const state = new State(document, window), dav = new DAV({ bypassCheck: !!document.querySelector('[data-disable-check]'), sortDirectoriesFirst: !!document.querySelector( '[data-sort-directories-first]' ), }), container = new Container(), header = new Header(state), list = new List(dav, state), footer = new Footer(dav, state), ui = new UI(document.body, dav, state); container.append(header, list); ui.append(container, footer); });