Code Monkey home page Code Monkey logo

webflow-m's Introduction

█░░░█ █▀▀ █▀▀▄ █▀▀ █░░ █▀▀█ █░░░█ ░░ █▀▄▀█ █▀▀ █▀▀▄ ░▀░ █░░█ █▀▄▀█ ░ ░░▀ █▀▀ 
█▄█▄█ █▀▀ █▀▀▄ █▀▀ █░░ █░░█ █▄█▄█ ▀▀ █░▀░█ █▀▀ █░░█ ▀█▀ █░░█ █░▀░█ ▄ ░░█ ▀▀█ 
░▀░▀░ ▀▀▀ ▀▀▀░ ▀░░ ▀▀▀ ▀▀▀▀ ░▀░▀░ ░░ ▀░░░▀ ▀▀▀ ▀▀▀░ ▀▀▀ ░▀▀▀ ▀░░░▀ █ █▄█ ▀▀▀

webflow-medium.js - Dynamically embed medium articles in Webflow 👍


About

webflow-medium is a script you can embed onto your hosted website like Webflow, Shopify, Square Space that allows you to directly inject your article meta data directly onto the page.

by @paulpierre, a blockchain developer @ https://www.conductiveresearch.com

join us we're hiring 🧑‍🔬🏴‍☠️👩‍🔬

Features

  • 🏴‍☠️ Get around Medium.com from accessing your own content! Embed your articles
  • 🔒 Preserves the style of your theme, just swaps content
  • ⚙️ Fill in CSS query selectors, and the rest is done
  • 👁️ Calculates amount of minutes it takes to read!
  • ⚠️ Set the maximum length of the title and description
  • 🖼️ Set a default image if no thumbnail is found

Metadata

  • Article title
  • Article description / preview
  • Article # of minutes to read
  • Article link

Get started

  1. Open webflow-medium.js and edit the section beneath // Configuration values
  2. Set your Medium.com users name under USERNAME
  3. Makes sure you setup a dummy layout on Webflow for the medium articles
  4. Configure your CSS selectors, embed script in Webflow and rock and roll!

How it works

Currently Medium does not really provide get APIs for your content or embed your medium articles in any meaningful way. Currently embedding results in styling the embed in Medium's style guide. This is silly, that's why I'm here.

  • Every medium has an RSS feed accessible via https://medium.com/feed/@yourusername
  • I simply pass this to a free RSS to JSON service
  • Loop and inject through the selectors .. very basic 💩

TODO:

  • Make certain Medium metadata optional
  • Limit description by word length rather than character length
  • Make images a >1 selector rather than individual. This was done bc of the particular site I was working with. Too lazy.
  • Create a function to directly parse the XHTML rather than relying on rss2json.com API

If you want additional features, find bugs, just submit an issue

Interested in blockchain and dApp development. Were hiring and looking for pirates 🏴‍☠️, https://www.conductiveresearch.com

Give this a ⭐ above ☝️ and me a follow on Twitter if you liked this 👍

webflow-m's People

Contributors

virusold0607 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.