mirror of
https://github.com/techgaun/active-forks.git
synced 2024-12-22 13:32:14 +01:00
refactor(date): added format friendly (#8)
This commit is contained in:
parent
c16032dbc0
commit
c179c1aa60
2 changed files with 2 additions and 0 deletions
|
@ -12,6 +12,7 @@
|
||||||
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/js/bootstrap.min.js" integrity="sha384-vBWWzlZJ8ea9aCX4pEW3rVHjgjt7zpkNpZk+02D9phzyeVkE+jo0ieGizqPLForn" crossorigin="anonymous"></script>
|
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/js/bootstrap.min.js" integrity="sha384-vBWWzlZJ8ea9aCX4pEW3rVHjgjt7zpkNpZk+02D9phzyeVkE+jo0ieGizqPLForn" crossorigin="anonymous"></script>
|
||||||
<script src="https://cdn.polyfill.io/v2/polyfill.min.js"></script>
|
<script src="https://cdn.polyfill.io/v2/polyfill.min.js"></script>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/datatables/1.10.19/js/jquery.dataTables.min.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/datatables/1.10.19/js/jquery.dataTables.min.js"></script>
|
||||||
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.22.2/moment.min.js"></script>
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
padding-top: 2rem;
|
padding-top: 2rem;
|
||||||
|
|
|
@ -36,6 +36,7 @@ function updateDT( data ) {
|
||||||
for ( let fork of data ) {
|
for ( let fork of data ) {
|
||||||
fork.repoLink = `<a href="https://github.com/${fork.full_name}">Link</a>`
|
fork.repoLink = `<a href="https://github.com/${fork.full_name}">Link</a>`
|
||||||
fork.ownerName = fork.owner.login
|
fork.ownerName = fork.owner.login
|
||||||
|
fork.pushed_at = moment(fork.pushed_at).fromNow()
|
||||||
forks.push( fork )
|
forks.push( fork )
|
||||||
}
|
}
|
||||||
const dataSet = forks.map( fork => window.columnNamesMap.map( colNM => fork[colNM[1]] ) )
|
const dataSet = forks.map( fork => window.columnNamesMap.map( colNM => fork[colNM[1]] ) )
|
||||||
|
|
Loading…
Reference in a new issue