SlideShare una empresa de Scribd logo
1 de 14
Single Page Web App: Manchester
Tech Meetups
by Sean O’Mahoney (@Sean12697)
Who?
 Computer Science at Manchester Metropolitan University
 Prolific Networker: ~200 Networking Events Attended
 Hackathons: 1st Place once, 2nd place three times, lost none
 Workshops/Talks: Run 4 (5 now), done 15 times (now 16)
 Likes Web & Data stuffs, does Photography
@Sean12697
What? (http://mcrmeetup.tech/)
Essentially, a service which will allow
you to find Meetup Groups, their
events, and filter through both.
@Sean12697
Inspiration / Research
 Spotify Playlist Generator - https://www.youtube.com/watch?v=eV3WkDAM3Hw
 GitHub Repository Video - https://github.com/lets-learn/spotify-playlist-generator
 Meetup RESTFUL API - https://www.meetup.com/meetup_api/
@Sean12697
How to get there?
MVP! MVP! MVP!!! (Minimum Viable Product)
Ideas (Features):
 Show All Meetups
 Search
 Filter into Categories
 Show Events
 Filter Events
 TechNW Integration
 Sorting
 Activity
Essential Features:
 Show All Meetups
 Show Events
 Search
MVP:
 Show All Meetups
Release:
 + Show Events
 + Search
Iteration x:
 + Filters
@Sean12697
MVP
 API Call compared from the tutorial, to research from the Meetup API
app.getAlbumTracks = (id) => $.ajax({
url: `https://api.spotify.com/v1/albums/${id}/tracks`,
method: 'GET',
dataType: 'json'
});
app.getMeetups = (meetup) => $.ajax({
url: 'https://api.meetup.com/' + meetup,
method: 'GET',
dataType: 'jsonp'
});
@Sean12697
MVP
 Function calls to the API compared from the tutorial, to what’s needed for the Meetup API
function initGetMeetups() {
console.log(meetups);
MeetupsJSON = MeetupsJSON.map(app.getMeetups);
$.when(...MeetupsJSON)
.then((...MeetupsJSON) => {
MeetupsJSON = MeetupsJSON.map(a => a[0].data);
console.log(MeetupsJSON); // MVP
});
}
app.getTracks = function(tracks) {
$.when(...tracks)
.then((...tracks) => {
tracks = tracks
.map(getDataObject)
.reduce((prev,curr) => [...prev,...curr],[]);
const randomPlayList = getRandomTracks(50,tracks);
app.createPlayList(randomPlayList);
})
};
 “meetups” & “MeetupJSON” = ["android_mcr", "BCS-Greater-Manchester-Branch“,.. ]
 $.when & .then are async’ call, .then doing the anonymous function once complete
 .map(a => a[0].data) to remove the JSONP padding ([0]), then async’ promise (.data)
@Sean12697
MVP (Console Logs)
 Whoop!
@Sean12697
MVP (Display & Responsiveness)
 What do we need? (Image, Name, Members).
 How should elements be, how do they change (thinking about CSS in Media Queries).
NAME
MEMBERS
NAME
MEMBERS
NAME
MEMBERS
NAME
MEMBERS
 Container (Div) = inline-block
 Picture and Text Elements
 Text Align: Centre or Left
@Sean12697
MVP (Resulting HTML)
<div class="group" id="0">
<div class="meetupImg">
<img src="https://secure.meetupstatic.com/photos/event/9/0/f/f/600_447577119.jpeg">
</div>
<div class="groupText">
<a href="https://www.meetup.com/android_mcr/" target="_blank">
<p class="groupName">Android Manchester</p>
</a>
<p>Members: 341</p>
</div>
</div>
@Sean12697
MVP (Resulting CSS)
.group {
display: inline-block;
width: 150px;
height: 280px;
margin: 10px;
overflow: hidden;
background-color: #fff;
transition-duration: 0.4s;
}
.group:hover {
transform: scale(1.1);
}
.groupText {
margin: 5px;
}
.group img {
object-fit: cover;
width: 150px;
height: 150px;
padding-bottom: 0px;
}
.groupName {
height: 40px;
overflow: hidden;
}
@media only screen and (min-width: 324px) and (max-width: 480px) {
.group {
width: 100%;
height: 100px;
margin: 8px 0px;
text-align: left;
overflow: hidden;
}
.group label {
width: 100px;
height: 100px;
padding: 0px;
margin: 0px;
display: inline-block;
overflow: hidden;
}
.meetupImg {
display: inline-block;
vertical-align: top;
}
.groupText {
padding: 0px 10px;
display: inline-block;
width: 50%;
}
.groupName {
margin: 0px;
margin-top: 10px;
}
.group img {
object-fit: cover;
width: 100px;
height: 100px;
padding-bottom: 0px;
}
.groupText p {
margin: 10px;
margin-left: 0px;
}
}
@Sean12697
MVP (Resulting JavaScript)
function drawMeetups(JSON) {
groupsContainer.innerHTML = "";
for (var i = 0; i < JSON.length; i++) {
var x = JSON[i];
var name = x.name;
var link = x.link;
var members = x.members;
var thumb = 'blank.jpg';
if (x.hasOwnProperty('group_photo')) {
thumb = x.group_photo.photo_link;
} else {
if(x.hasOwnProperty('organizer')) {
if (x.organizer.hasOwnProperty('photo')) {
thumb = x.organizer.photo.photo_link;
}
}
} groupsContainer.insertAdjacentHTML('beforeend', '<div class="group" id="' + i + '"><div class="meetupImg"><img src="' + thumb
+ '"></div><div class="groupText"><a href="' + link + '" target="_blank"><p class="groupName">' + name + '</p></a><p>Members: ' +
members + '</p></div></div>');
}
}
 Clear our container (which will have a loader)
 Go through each object in our returned JSON
 Put the content we need in variables
 Do error correction on some (don’t make
assumptions)
 Generate HTML and insert it within a container
element (which has been defined)
@Sean12697
MVP Complete (“Show
All Meetups”)
 Within 43 lines of JavaScript
 https://github.com/Sean12697/mcrmeetup
tech_workshop
@Sean12697
Tips & Tricks
 Spinner (for good UX) - https://medium.com/@kayliepoitras/css3-style-animation-preloaders-
d07914bb84a8
@Sean12697

Más contenido relacionado

Similar a Single Page Web App

SPS Nashville Modern Sharepoint Experience
SPS Nashville Modern Sharepoint ExperienceSPS Nashville Modern Sharepoint Experience
SPS Nashville Modern Sharepoint ExperienceTheresa Lubelski
 
EmployeePages The next generation staff directory
EmployeePages The next generation staff directoryEmployeePages The next generation staff directory
EmployeePages The next generation staff directoryTIMETOACT GROUP
 
Detailed Technical Portfolio
Detailed Technical PortfolioDetailed Technical Portfolio
Detailed Technical PortfolioTahirMustafa
 
Chris McNulty: ECM/WCM Planning, Implementation and Migration Strategies
Chris McNulty: ECM/WCM Planning, Implementation and Migration StrategiesChris McNulty: ECM/WCM Planning, Implementation and Migration Strategies
Chris McNulty: ECM/WCM Planning, Implementation and Migration StrategiesSharePoint Saturday NY
 
Continental Airlines 2009 Microsoft SharePoint Conference Presentation
Continental Airlines 2009 Microsoft SharePoint Conference PresentationContinental Airlines 2009 Microsoft SharePoint Conference Presentation
Continental Airlines 2009 Microsoft SharePoint Conference PresentationDenise Wilson
 
Semantic Web, an introduction for bioscientists
Semantic Web, an introduction for bioscientistsSemantic Web, an introduction for bioscientists
Semantic Web, an introduction for bioscientistsEmanuele Della Valle
 
Front End Lecture 1.pptx
Front End Lecture 1.pptxFront End Lecture 1.pptx
Front End Lecture 1.pptxmalise2997
 
Fecc 12517-sd
Fecc 12517-sdFecc 12517-sd
Fecc 12517-sdThinkful
 
Twitter Bootstrap Presentation
Twitter Bootstrap PresentationTwitter Bootstrap Presentation
Twitter Bootstrap Presentationaneeshalidina
 
SharePoint Framework SPS Madrid 2016
SharePoint Framework SPS Madrid 2016SharePoint Framework SPS Madrid 2016
SharePoint Framework SPS Madrid 2016Sonja Madsen
 
Fecrash10:3:17 sd
Fecrash10:3:17 sdFecrash10:3:17 sd
Fecrash10:3:17 sdThinkful
 
SharePoint Governance: From Chaos to Success in 10 Steps
SharePoint Governance: From Chaos to Success in 10 StepsSharePoint Governance: From Chaos to Success in 10 Steps
SharePoint Governance: From Chaos to Success in 10 StepsJoel Oleson
 
Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...
	Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...	Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...
Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...hannonhill
 
Structured Data and Semantic SEO
Structured Data and Semantic SEOStructured Data and Semantic SEO
Structured Data and Semantic SEOMatthew Brown
 
WSO2Con-Asia-2014 : Build a Connected Business (final keynote)
WSO2Con-Asia-2014 : Build a Connected Business (final keynote)WSO2Con-Asia-2014 : Build a Connected Business (final keynote)
WSO2Con-Asia-2014 : Build a Connected Business (final keynote)Asanka Abeysinghe
 
WSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected Business
WSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected BusinessWSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected Business
WSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected BusinessWSO2
 
Messy Web, Meet Clean(er) Web: An Experiment in Social Media Archiving
Messy Web, Meet Clean(er) Web: An Experiment in Social Media ArchivingMessy Web, Meet Clean(er) Web: An Experiment in Social Media Archiving
Messy Web, Meet Clean(er) Web: An Experiment in Social Media ArchivingRachel Trent
 
RajeshBalu_Resume
RajeshBalu_ResumeRajeshBalu_Resume
RajeshBalu_ResumeRajesh Balu
 

Similar a Single Page Web App (20)

SPS Nashville Modern Sharepoint Experience
SPS Nashville Modern Sharepoint ExperienceSPS Nashville Modern Sharepoint Experience
SPS Nashville Modern Sharepoint Experience
 
DIGITAL MARKETING.pptx
DIGITAL MARKETING.pptxDIGITAL MARKETING.pptx
DIGITAL MARKETING.pptx
 
EmployeePages The next generation staff directory
EmployeePages The next generation staff directoryEmployeePages The next generation staff directory
EmployeePages The next generation staff directory
 
Detailed Technical Portfolio
Detailed Technical PortfolioDetailed Technical Portfolio
Detailed Technical Portfolio
 
Chris McNulty: ECM/WCM Planning, Implementation and Migration Strategies
Chris McNulty: ECM/WCM Planning, Implementation and Migration StrategiesChris McNulty: ECM/WCM Planning, Implementation and Migration Strategies
Chris McNulty: ECM/WCM Planning, Implementation and Migration Strategies
 
Continental Airlines 2009 Microsoft SharePoint Conference Presentation
Continental Airlines 2009 Microsoft SharePoint Conference PresentationContinental Airlines 2009 Microsoft SharePoint Conference Presentation
Continental Airlines 2009 Microsoft SharePoint Conference Presentation
 
Semantic Web, an introduction for bioscientists
Semantic Web, an introduction for bioscientistsSemantic Web, an introduction for bioscientists
Semantic Web, an introduction for bioscientists
 
Front End Lecture 1.pptx
Front End Lecture 1.pptxFront End Lecture 1.pptx
Front End Lecture 1.pptx
 
Lecture7
Lecture7Lecture7
Lecture7
 
Fecc 12517-sd
Fecc 12517-sdFecc 12517-sd
Fecc 12517-sd
 
Twitter Bootstrap Presentation
Twitter Bootstrap PresentationTwitter Bootstrap Presentation
Twitter Bootstrap Presentation
 
SharePoint Framework SPS Madrid 2016
SharePoint Framework SPS Madrid 2016SharePoint Framework SPS Madrid 2016
SharePoint Framework SPS Madrid 2016
 
Fecrash10:3:17 sd
Fecrash10:3:17 sdFecrash10:3:17 sd
Fecrash10:3:17 sd
 
SharePoint Governance: From Chaos to Success in 10 Steps
SharePoint Governance: From Chaos to Success in 10 StepsSharePoint Governance: From Chaos to Success in 10 Steps
SharePoint Governance: From Chaos to Success in 10 Steps
 
Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...
	Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...	Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...
Superautomatic! Data Feeds, Bricks, and Blocks, with Server-side Transformat...
 
Structured Data and Semantic SEO
Structured Data and Semantic SEOStructured Data and Semantic SEO
Structured Data and Semantic SEO
 
WSO2Con-Asia-2014 : Build a Connected Business (final keynote)
WSO2Con-Asia-2014 : Build a Connected Business (final keynote)WSO2Con-Asia-2014 : Build a Connected Business (final keynote)
WSO2Con-Asia-2014 : Build a Connected Business (final keynote)
 
WSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected Business
WSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected BusinessWSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected Business
WSO2Con Asia 2014 - Complete Your Corporate Jigsaw - Build a Connected Business
 
Messy Web, Meet Clean(er) Web: An Experiment in Social Media Archiving
Messy Web, Meet Clean(er) Web: An Experiment in Social Media ArchivingMessy Web, Meet Clean(er) Web: An Experiment in Social Media Archiving
Messy Web, Meet Clean(er) Web: An Experiment in Social Media Archiving
 
RajeshBalu_Resume
RajeshBalu_ResumeRajeshBalu_Resume
RajeshBalu_Resume
 

Más de Sean O'Mahoney

Tips & Tricks From The Experts
Tips & Tricks From The ExpertsTips & Tricks From The Experts
Tips & Tricks From The ExpertsSean O'Mahoney
 
Managing Your Assessments
Managing Your AssessmentsManaging Your Assessments
Managing Your AssessmentsSean O'Mahoney
 
Making the Most of Lectures
Making the Most of LecturesMaking the Most of Lectures
Making the Most of LecturesSean O'Mahoney
 
Intro to Cryptography (Futures Friday)
Intro to Cryptography (Futures Friday)Intro to Cryptography (Futures Friday)
Intro to Cryptography (Futures Friday)Sean O'Mahoney
 
Front-end Performance 101
Front-end Performance 101Front-end Performance 101
Front-end Performance 101Sean O'Mahoney
 
University Recommendations
University Recommendations University Recommendations
University Recommendations Sean O'Mahoney
 
Creating Your Own Static Website Generator
Creating Your Own Static Website GeneratorCreating Your Own Static Website Generator
Creating Your Own Static Website GeneratorSean O'Mahoney
 
BCS Hackathon: Check Your Numbers
BCS Hackathon: Check Your NumbersBCS Hackathon: Check Your Numbers
BCS Hackathon: Check Your NumbersSean O'Mahoney
 

Más de Sean O'Mahoney (10)

Tips & Tricks From The Experts
Tips & Tricks From The ExpertsTips & Tricks From The Experts
Tips & Tricks From The Experts
 
Managing Your Assessments
Managing Your AssessmentsManaging Your Assessments
Managing Your Assessments
 
Making the Most of Lectures
Making the Most of LecturesMaking the Most of Lectures
Making the Most of Lectures
 
Intro to Cryptography (Futures Friday)
Intro to Cryptography (Futures Friday)Intro to Cryptography (Futures Friday)
Intro to Cryptography (Futures Friday)
 
CompiledMCR
CompiledMCRCompiledMCR
CompiledMCR
 
Front-end Performance 101
Front-end Performance 101Front-end Performance 101
Front-end Performance 101
 
University Recommendations
University Recommendations University Recommendations
University Recommendations
 
Creating Your Own Static Website Generator
Creating Your Own Static Website GeneratorCreating Your Own Static Website Generator
Creating Your Own Static Website Generator
 
BCS Hackathon: Check Your Numbers
BCS Hackathon: Check Your NumbersBCS Hackathon: Check Your Numbers
BCS Hackathon: Check Your Numbers
 
TAPIT Pitch Idea
TAPIT Pitch IdeaTAPIT Pitch Idea
TAPIT Pitch Idea
 

Último

From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfPrecisely
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 

Último (20)

From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 

Single Page Web App

  • 1. Single Page Web App: Manchester Tech Meetups by Sean O’Mahoney (@Sean12697)
  • 2. Who?  Computer Science at Manchester Metropolitan University  Prolific Networker: ~200 Networking Events Attended  Hackathons: 1st Place once, 2nd place three times, lost none  Workshops/Talks: Run 4 (5 now), done 15 times (now 16)  Likes Web & Data stuffs, does Photography @Sean12697
  • 3. What? (http://mcrmeetup.tech/) Essentially, a service which will allow you to find Meetup Groups, their events, and filter through both. @Sean12697
  • 4. Inspiration / Research  Spotify Playlist Generator - https://www.youtube.com/watch?v=eV3WkDAM3Hw  GitHub Repository Video - https://github.com/lets-learn/spotify-playlist-generator  Meetup RESTFUL API - https://www.meetup.com/meetup_api/ @Sean12697
  • 5. How to get there? MVP! MVP! MVP!!! (Minimum Viable Product) Ideas (Features):  Show All Meetups  Search  Filter into Categories  Show Events  Filter Events  TechNW Integration  Sorting  Activity Essential Features:  Show All Meetups  Show Events  Search MVP:  Show All Meetups Release:  + Show Events  + Search Iteration x:  + Filters @Sean12697
  • 6. MVP  API Call compared from the tutorial, to research from the Meetup API app.getAlbumTracks = (id) => $.ajax({ url: `https://api.spotify.com/v1/albums/${id}/tracks`, method: 'GET', dataType: 'json' }); app.getMeetups = (meetup) => $.ajax({ url: 'https://api.meetup.com/' + meetup, method: 'GET', dataType: 'jsonp' }); @Sean12697
  • 7. MVP  Function calls to the API compared from the tutorial, to what’s needed for the Meetup API function initGetMeetups() { console.log(meetups); MeetupsJSON = MeetupsJSON.map(app.getMeetups); $.when(...MeetupsJSON) .then((...MeetupsJSON) => { MeetupsJSON = MeetupsJSON.map(a => a[0].data); console.log(MeetupsJSON); // MVP }); } app.getTracks = function(tracks) { $.when(...tracks) .then((...tracks) => { tracks = tracks .map(getDataObject) .reduce((prev,curr) => [...prev,...curr],[]); const randomPlayList = getRandomTracks(50,tracks); app.createPlayList(randomPlayList); }) };  “meetups” & “MeetupJSON” = ["android_mcr", "BCS-Greater-Manchester-Branch“,.. ]  $.when & .then are async’ call, .then doing the anonymous function once complete  .map(a => a[0].data) to remove the JSONP padding ([0]), then async’ promise (.data) @Sean12697
  • 8. MVP (Console Logs)  Whoop! @Sean12697
  • 9. MVP (Display & Responsiveness)  What do we need? (Image, Name, Members).  How should elements be, how do they change (thinking about CSS in Media Queries). NAME MEMBERS NAME MEMBERS NAME MEMBERS NAME MEMBERS  Container (Div) = inline-block  Picture and Text Elements  Text Align: Centre or Left @Sean12697
  • 10. MVP (Resulting HTML) <div class="group" id="0"> <div class="meetupImg"> <img src="https://secure.meetupstatic.com/photos/event/9/0/f/f/600_447577119.jpeg"> </div> <div class="groupText"> <a href="https://www.meetup.com/android_mcr/" target="_blank"> <p class="groupName">Android Manchester</p> </a> <p>Members: 341</p> </div> </div> @Sean12697
  • 11. MVP (Resulting CSS) .group { display: inline-block; width: 150px; height: 280px; margin: 10px; overflow: hidden; background-color: #fff; transition-duration: 0.4s; } .group:hover { transform: scale(1.1); } .groupText { margin: 5px; } .group img { object-fit: cover; width: 150px; height: 150px; padding-bottom: 0px; } .groupName { height: 40px; overflow: hidden; } @media only screen and (min-width: 324px) and (max-width: 480px) { .group { width: 100%; height: 100px; margin: 8px 0px; text-align: left; overflow: hidden; } .group label { width: 100px; height: 100px; padding: 0px; margin: 0px; display: inline-block; overflow: hidden; } .meetupImg { display: inline-block; vertical-align: top; } .groupText { padding: 0px 10px; display: inline-block; width: 50%; } .groupName { margin: 0px; margin-top: 10px; } .group img { object-fit: cover; width: 100px; height: 100px; padding-bottom: 0px; } .groupText p { margin: 10px; margin-left: 0px; } } @Sean12697
  • 12. MVP (Resulting JavaScript) function drawMeetups(JSON) { groupsContainer.innerHTML = ""; for (var i = 0; i < JSON.length; i++) { var x = JSON[i]; var name = x.name; var link = x.link; var members = x.members; var thumb = 'blank.jpg'; if (x.hasOwnProperty('group_photo')) { thumb = x.group_photo.photo_link; } else { if(x.hasOwnProperty('organizer')) { if (x.organizer.hasOwnProperty('photo')) { thumb = x.organizer.photo.photo_link; } } } groupsContainer.insertAdjacentHTML('beforeend', '<div class="group" id="' + i + '"><div class="meetupImg"><img src="' + thumb + '"></div><div class="groupText"><a href="' + link + '" target="_blank"><p class="groupName">' + name + '</p></a><p>Members: ' + members + '</p></div></div>'); } }  Clear our container (which will have a loader)  Go through each object in our returned JSON  Put the content we need in variables  Do error correction on some (don’t make assumptions)  Generate HTML and insert it within a container element (which has been defined) @Sean12697
  • 13. MVP Complete (“Show All Meetups”)  Within 43 lines of JavaScript  https://github.com/Sean12697/mcrmeetup tech_workshop @Sean12697
  • 14. Tips & Tricks  Spinner (for good UX) - https://medium.com/@kayliepoitras/css3-style-animation-preloaders- d07914bb84a8 @Sean12697

Notas del editor

  1. [Small Demo]