This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fs = require('fs-extra'); | |
const cal = require('./cal.js'); | |
(async function() { | |
const uniq = []; | |
const newCal = []; | |
cal.map(event => { | |
const hash = `${event.match(/SUMMARY:(.*)\n/)[1]}::${event.match(/DTSTART(.*)\n/)[1]}`; | |
if (!uniq.includes(hash)) { | |
uniq.push(hash); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* I couldn't find online any way of managing entities with a M2M relationship in react-admin with hasura backend, | |
* so here are mine. | |
* Example of what you can do: to the Edit view of your Movie resource, add DeletableRelatedResourceList | |
* to list and delete associated actors, and M2MRelatedResourceSelectInput to add new associated actors | |
* (with an intermediary table movie_actors). | |
* | |
* Done with [email protected] | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
Ember Data: Dependent Relationships (Ember Data v1.13.x) | |
This package extends Ember Data to support creating relationships | |
where a model's dirty state depends not only on its own attributes | |
but on the dirty state of models in dependent relationships as well. | |
```javascript | |
App.Thing = DS.Model.extend({ | |
name : DS.attr('string'), |