Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add form to landing page for users to submit suggested talks #13

Open
jonathanKingston opened this issue Dec 15, 2015 · 6 comments
Open

Comments

@jonathanKingston
Copy link

Can there be a suggested talks section added to: https://github.com/nottsjs/speakers

Something like:

Suggested talks

At NottsJS we are happy to look at all talk suggestions however some suggested talk ideas are:

  • Application performance
  • Security
  • Future syntax of ECMA
  • JavaScript Frameworks
    • Comparison of frameworks
    • Review of features
  • Build tools
@iancrowther
Copy link
Member

i think this is a great idea.. i would go simple

could that be a label in the feedback repo? "suggested-topic"

then use the gh api to render on /suggested-topics

@jonathanKingston
Copy link
Author

Yeah seems a good idea as that way they can rotate.

#suggested-talks {
  display: none;
}
#suggested-talks.loaded {
  display: block;
}
<div id="suggested-talks">
  <h2>Suggested talks</h2>
  <p>At NottsJS we are happy to look at all talk suggestions however some suggested talk ideas are:</p>
  <ul></ul>
</div>
let suggestedTalks = document.querySelector('#suggested-talks');
let list = document.querySelector('#suggested-talks ul');
let url = 'https://api.github.com/repos/nottsjs/feedback/issues?labels=suggested-topic';

function createItem(subject) {
  let item = document.createElement('li');
  item.innerText = subject;
  list.appendChild(item);
}

function renderList(issues) {
  suggestedTalks.className += ' loaded';
  list.innerText = '';

  issues.forEach((issue) => {
    createItem(issue.title);
  });
}

fetch(url).then((response) => {
  return response.json();
}).then((response) => {
  renderList(response);
})

@iancrowther
Copy link
Member

super happy with that

@jonathanKingston
Copy link
Author

This should probably have a build process to be added to the site repo:

  • Use node to make a static page
  • Use babel to compile the code and inject into the HTML

@iancrowther
Copy link
Member

@jonathanKingston - any chance you could make this a reality?

@jonathanKingston
Copy link
Author

@iancrowther yup was waiting for your response on deciding how you wanted the build process added to the site and if that is ok?
(Looking at my past comment I realise I should have made that clear haha)

@iancrowther iancrowther changed the title Suggested talks Add form to landing page for users to submit suggested talks Dec 31, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants