Scarica i file del calendario iCal dall'URL di Facebook o dal numero dell'evento. Utilizza un service worker e può essere utilizzata offline e installata come PWA (Progressive Web App). https://mobilizon.it
Go to file
Ondrej Synacek da896da6f8
Merge pull request #26 from comatory/dependabot/npm_and_yarn/tmpl-1.0.5
chore(deps): bump tmpl from 1.0.4 to 1.0.5
2021-09-22 07:44:43 +02:00
.ebextensions add node command for AWS 2019-11-02 11:30:02 +01:00
.github/workflows feature: set up Firebase deploy 2020-12-25 13:48:45 +01:00
docs add preview gif to readmer 2020-01-19 19:40:29 +01:00
functions Merge pull request #17 from comatory/dependabot/npm_and_yarn/functions/lodash-4.17.21 2021-09-22 07:44:01 +02:00
lib fix: use browser's timezone to reflect correct time and date 2021-01-02 20:17:21 +01:00
logs add logger and daily rotating log files 2019-10-24 10:32:01 +02:00
mocks add specs for ICS retriever 2020-07-19 08:14:29 +02:00
test fix: do not attempt to parse non-existent FB pages 2020-12-26 21:03:03 +01:00
.firebaserc fix issues with deployment due to winston logging getting in the way 2020-11-15 15:13:49 +01:00
.gitignore remove firebase caching folder from git 2020-11-15 16:09:22 +01:00
database.rules.json fix: allow writing logs to firebase DB 2020-12-12 14:04:04 +01:00
firebase.json feature: add loggers and save logs to DB when using Firebase 2020-11-15 21:33:47 +01:00
package-lock.json Merge pull request #26 from comatory/dependabot/npm_and_yarn/tmpl-1.0.5 2021-09-22 07:44:43 +02:00
package.json 2.0.0 2021-01-02 20:18:07 +01:00
readme.MD fix: change hosted app URL 2021-08-30 08:39:18 +02:00
webpack.common.js fix: add missing Buffer polyfill 2020-12-25 13:57:51 +01:00
webpack.dev.js feature: add Svelte framework to app, refactor tracking panel into Svelte component 2020-12-15 21:49:15 +01:00
webpack.prod.js feature: add Svelte framework to app, refactor tracking panel into Svelte component 2020-12-15 21:49:15 +01:00

readme.MD

Build Status

fb2iCal

fb2iCal animated gif of the app

This app allows you to download iCal calendar files from Facebook URL / event number.

You can use it as a service at https://fb2ical-3051b.web.app/ or use this repository to launch your own instance.

The page that is served by the app uses a service worker and can be used offline and installed as PWA (Progressive Web App).

The site can run and download ICS file without JavaScript just fine. When JS is enabled, the server only downloads HTML file, parsing and creation of iCal file is performed inside the browser. The results will be same for both JS-enabed / disabled approach as the parser code is actually shared between browser and server.

Installing

Run npm install. App should be compatible with Node v10.

Installing with Firebase

Additionally to npm install in root directory, make sure you navigate to functions/ directory and run npm install there. You need to set up Firebase service and install Firebase CLI in order to deploy and develop for Firebase service.

Development

It can run in environment with NodeJS 10 installed. It does not use Facebook API for retrieving information, instead it relies on crawling and scraping event URL. This means that it can stop working or the results might not be reliable so use this at your own risk.

Run development server: npm run start:dev.

Run development server with debugger npm run start:dev:inspect.

Development with Firebase

Run npm run start:dev:firebase from project root. This will run webpack development server for frontend and also launch Firebase emulator. Unfortunately you will not get live reload on frontend because it is actually served using Firebase hosting emulator, so you will need to refresh the browser manually.

Static assets

The frontend / assets are built by webpack and put into dist/ folder. These assets are then served statically.

Deployment

The command npm run start will build the assets and start the server in production mode.

The app is stateless and does not need any persistent storage.

The app is automatically set up to create logs in logs/ directory each day but it's up to your environment if the file system is persisted.

Deployement with Firebase

Run npm run deploy:firebase to deploy everything. Notice: the project contains symbolic link between lib/ and functions/ directories so Firebase functions can actually use the application code, otherwise it would not get uploaded. Do not remove this symbolic link.

HTTPS

App contains middleware that will redirect all traffic to HTTPS if the requests contain header X-FORWARDED-PROTO. For this to work, the middleware has to be enabled by setting environment variable ENFORCE_HTTPS to value 1.

There are environment variables for setting pu SSL certificate from Let's Encrypt (acme challenge):

  • CERT_ENDPOINT: endpoint without leading slash such as .well-known/acme-challenge
  • CERT_SECRET

This way you can set up the endpoint that will reply with secret and this should allow you to generate key pairs.