Skip to content

Instantly share code, notes, and snippets.

View MercurA's full-sized avatar
☯️

Horea MercurA

☯️
View GitHub Profile
@MercurA
MercurA / privacy-policy.md
Created April 22, 2026 16:16
HabiTrakr Privacy Policy

Privacy Policy for HabiTrakr

Last updated: April 22, 2026

Overview

HabiTrakr ("the App") is a personal habit tracking application developed by MercurA. This Privacy Policy explains how the App handles your information.

Data Storage

@MercurA
MercurA / http.js
Last active January 15, 2022 12:23
//server/http.js
const express = require('express') // import express library
const cors = require('cors') // import CORS (Cross Origin Resource Sharing) to handle sharing between React and Nodejs server
exports.server = () => {
// we call on express to return us its methods
const app = express();
app.use(express.json()) // we USE express to parse object
app.use(express.urlencoded({extended: true})) // makes server able to decode URLs
@MercurA
MercurA / constants.js
Last active March 19, 2018 09:05
contants
exports = module.exports = ()=>{
let settings = {
message: 3000
}
return settings;
}
exports['@singleton'] = true;
@MercurA
MercurA / http.js
Last active March 13, 2018 14:38
http.js
const express = require('express');
const bodyParser = require('body-parser'); <--- add this
exports = module.exports = (setting, routing, handler) => { <-- remove routing and add handler path
let app = express(),
port = setting.http.port,
host = setting.http.host;
//routing.start(app, false); <-- comment it
app.use(bodyParser.urlencoded({ extended: false })); <--- add this
import { Component, OnInit, OnDestroy } from '@angular/core';
import {Subject} from 'rxjs/Subject';
import { Subscription } from 'rxjs/Subscription';
@Component({
selector: 'button',
templateURL: 'some.component.html',
styleUrls: ['some.component.css']
});
import { Injectable } from '@angular/core';
import { HttpClient} from '@angular/common/http'
import {Observable} from 'rxjs/Observable'
@Injectable()
class ApiService {
constructor(private http: HttpClient ){}
getList():Observable<any>{
return this.http
@MercurA
MercurA / logout.css
Created January 8, 2018 07:38
logout
#park-list_container_logout{
position: fixed;
height: 50px;
width: 50px;
border: 1px solid #2c2f5a;
top: 68px;
right: 10px;
transition: 1s all ease;
cursor: pointer;
z-index: 10;
<!DOCTYPE html>
<html>
<head>
<meta charset="utf8">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/css/bootstrap.min.css" integrity="sha384-rwoIResjU2yc3z8GV/NPeZWAv56rSmLldC3R/AZzGRnGxQQKnKkoFVhFQhNUwEyJ" crossorigin="anonymous">
<link rel="stylesheet" href="stylesheet.css">
<link href="https://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
</head>
<body>
<nav class="nav navbar-inverse sticky-top bg-inverse navbar_custom">
@MercurA
MercurA / game.py
Created June 28, 2017 13:11
Practice OOP in python
from sys import exit
from random import randint
#Creating a class for characters.
class Character(object):
def __init__(self,name,types,attack,armor):
self.name = name
self.types = types