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
import datetime | |
from django.conf import settings | |
from django.contrib.auth import logout | |
from django.contrib.sessions.models import Session | |
from django.http import HttpRequest | |
from importlib import import_module | |
now = datetime.datetime.now() | |
session_engine = import_module(settings.SESSION_ENGINE) | |
sessions = Session.objects.filter(expire_date__gt=now) |
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
REACT NATIVE IOS vs ANDROID FONT USE | |
Tested for React Native 0.41+ | |
IOS: | |
- Place the fonts in the assets and make sure they are bundled along | |
- On iOS, fontFamily in Text match the Font Family name as described in Font Book (macOS). Font weights can be specified exactly. | |
ANDROID: | |
On Android, there are two ways of using fonts: |
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
from django.urls import path | |
from .feeds import LatestEntriesFeed | |
urlpatterns = [ | |
# ... | |
path('latest/feed/', LatestEntriesFeed()), | |
# ... | |
] |
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
from django.contrib.syndication.views import Feed | |
from django.urls import reverse | |
from blog.models import BlogPost | |
class LatestEntriesFeed(Feed): | |
title = "Blog | Olamigoke Philip" | |
link = "/feeds/" | |
description = "I'm Ola; a Full stack web developer. I also ..." | |
def items(self): |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
<title>Document</title> | |
</head> | |
<body> | |
<style> | |
#intro { |
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
Afghanistan | |
Albania | |
Algeria | |
Andorra | |
Angola | |
Antigua and Barbuda | |
Argentina | |
Armenia | |
Australia | |
Austria |
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
# | |
from tkinter import * | |
class Application(Frame): | |
"""A updated Version of delete me. """ | |
def __init__(self, master): | |
super(Application, self).__init__(master) | |
self.grid() | |
self.create_widget() |