Skip to content

Instantly share code, notes, and snippets.

View bharathjinka09's full-sized avatar
🏠
Working from home

JINKA RANGA BHARATH bharathjinka09

🏠
Working from home
View GitHub Profile
@bharathjinka09
bharathjinka09 / app.py
Created February 1, 2022 11:08 — forked from arundhaj/app.py
Documenting Flask REST APIs with Swagger Specification and Swagger UI
from apispec import APISpec
from apispec.ext.marshmallow import MarshmallowPlugin
from apispec_webframeworks.flask import FlaskPlugin
from flask import Flask, jsonify, render_template, send_from_directory
from marshmallow import Schema, fields
app = Flask(__name__, template_folder='swagger/templates')
@app.route('/')
@bharathjinka09
bharathjinka09 / drf-api-swagger-doc.md
Created February 1, 2022 07:37 — forked from dotja/drf-api-swagger-doc.md
Django REST Framework API documentation using Swagger

API Documentation with DRF and Swagger

Overview:

  • We need to create a schema. The schema outlines all the endpoints and actions of our API.

  • We need to create the documentation that is a more human-readable form of the schema.

Steps:

@bharathjinka09
bharathjinka09 / typescript-crash.ts
Created August 20, 2021 16:20 — forked from bradtraversy/typescript-crash.ts
Basic intro to TypeScript (From YouTube Crash Course)
// Basic Types
let id: number = 5
let company: string = 'Traversy Media'
let isPublished: boolean = true
let x: any = 'Hello'
let ids: number[] = [1, 2, 3, 4, 5]
let arr: any[] = [1, true, 'Hello']
// Tuple
@bharathjinka09
bharathjinka09 / util.js
Created May 27, 2021 04:34 — forked from gitdagray/util.js
Javascript Utility Functions
// Youtube tutorial here: https://youtu.be/LDgPTw6tePk
// These functions are designed to be exported, but you could create a class instead. See tutorial video.
// #1 proper case
export const properCase = (string) => {
return `${string[0].toUpperCase()}${string.slice(1).toLowerCase()}`;
};
@bharathjinka09
bharathjinka09 / myscript.sh
Created October 19, 2020 07:59 — forked from bradtraversy/myscript.sh
Basic Shell Scripting
#! /bin/bash
# ECHO COMMAND
# echo Hello World!
# VARIABLES
# Uppercase by convention
# Letters, numbers, underscores
NAME="Bob"
# echo "My name is $NAME"