Are there any more example regard how to use Updates? - telethon

I have been trying to improve my application by incorporating updates. However, the current documentation is very confusing on for example how updates would be structure for a chat or a channel.
Any advice on this topic would be much appreciated. Thank you in advance!

Things have changed a lot, but the official Telethon documentation probably explains them good enough now.
You can also view single-file Telethon examples or real world Telethon projects. Maybe I'm a bit late for the answer but hopefully helps other people :)

Related

Vue architecture example for inspiration

TL;DR; Please share really complex, clean and well structured vue project.
Hello and thanks for reading!
I have been using react for quite a while. I know how to cook complex application and keep it simple and well structured.
I have learned Vue and feel I can handle any task. But I am always thinking: Am I using the best solution? Do that code will cause problems in future? etc. Official docs provide list of projects. But there are a lot and most of them either simple or messy.
So I'm looking for vue code samples (not basic and simple), and just good idea of what to use and what I should avoid. I am interested in code architecture, how should I split files, folders etc. And I would be gratitude for any good and real live experience you are ready to share.
Thanks in advance!
Hi you may want to check this collection of awesome stuff with Vue, in particular the projects section

Is there any sandbox for stackoverflow APi?

Did anyone ever met links to StackOverflow sandbox for their own API?
I have found couple of questions which were made for testing answers( https://meta.stackexchange.com/questions/51812/the-api-sandbox) , but no way to test questions.
Well, it seems that there is no such thing as sandbox for stackoverlow API. Just make a test question/answer, mark them properly and then delete.
For anyone who will be asearching for sandbox. You can do as mentioned above and then delete the question. You can also make api for the answer and make similar for question (they are not that much different). The same qnswer was received at meta.
That is awesome! I reallyy hope that will work and I would be able to test. Also, probably anyone can use this answer as testing one. Any way, that's just an offer!

Advanced Ajax with RoR and jQuery UI

I don't have much web development practical experience although I had studied a lot on the web (Treehouse, CodeSchool, other tutorials and articles).
I have found some explanations on how to use Ajax with RoR and jQuery. But I'm having difficulties to understand how to solve my problem as the explanations often use jquery-ujs that I suppose I can't use in my case.
My problem is difficult to explain here but is similar to implementing this shopping cart on RoR, including more parameters like price
The jQuery UI is working for me in my RoR application. What is missing is the AJAX part and how to make it work with RoR
I have found some questions here on StackOverflow that is about this topic but it didn't helped much as they are probably for more advanced users.
So, I believe that the best help would be a tutorial or book or some other reference that is more similar to my problem. However any advice or other kind of directions may help
After struggling a lot, finally I solved my problem.
I will post here the resources and some tricks that helped me. I hope it can help others. StackOverflow didn't let me post all the links. For this reason, I just gave some hints that may help to find some resources.
About the jQuery Ajax concepts, I recommend Code School jquery course "The Return Flight".
The second thing that I think helps is learn to debug. Firebug helped me a log to debug the client side/javascript/Ajax. This link may help on that:
http://www.zyxware.com/articles/2642/debugging-tips-how-to-debug-ajax-requests-using-mozilla-firefox-and-firebug
Since the problem may be to debug RoR. Look for a RailCast on the subject.
One of the things that I took some time is if it would be better to use $.ajax(), $.post(), $.get() or $.getJSON(). The link below may explain better but to sum it up, $.ajax() is the more generic one and the other are simpler ones and that call $.ajax() with specific parameters.
Difference between $.post and $.ajax?
It is important to understand how RoR routing works to call the right url with the right $.ajax() type. "rake routes" may help.
This link may also help to use the right $.ajax() type.
http://old.thoughtsincomputation.com/posts/understanding-rest-in-rails-3
Finally, to send the right format from the javascript to RoR controller, this link may help:
How to send and store data to rails through jquery/ajax as a JSON object?

Simple example of Masstransit with RabbitMQ

I want to use MassTransit bus with RabbitMQ. But I am not able to find a simple example. I am looking for example which will get me started.
What I have tried.
googled: But most the examples are using MSMQ or they using too many configuration options.
GitHub: I looked a the GitHub for MassTransit (https://github.com/MassTransit/MassTransit/tree/master/src/Samples) But the example here is heavily loaded. It's very hard to understand for beginners.
Reading docs: I have started reading docs but it will take some time before I finish it. I am hoping if someone shares a link to simple example which will get me started.
Please provide your suggestion.
Here's a simple, good pub-sub example using MassTransit and RabbitMQ both.
http://looselycoupledlabs.com/2014/06/masstransit-publish-subscribe-example/
In case the article link does not work, here's the link to the source code:
https://github.com/dprothero/MtPubSubExample
Thanks to the author of course!
MassTransit implements a lot of concepts and provides great many features with a very small surface API. There's no simple way to describe everything it does, because the problems it helps to solve are not simple, but an example can be made small.
Have a look at this sample I have for testing throughput:
https://github.com/et1975/Throughput-Test
The only "extra" that one might find unnecessary is Dependency Injection integration. You'd want one in most cases, but it does hide how certain bits interact.
Look at https://groups.google.com/forum/?fromgroups#!forum/masstransit-discuss for more help.
Cheers,
ET.

Does anyone know a better alternative to Google Translate API?

I already did similar search terms for this topic in this forum.
https://stackoverflow.com/questions/6151668/alternative-to-google-translate-api
But that post is a bit old.. Things may have changed for about a year. And I wonder does anybody know if there's any better REST-based API service that I can use out there since that post was last posted.
Thanks.
I guess Bing translator could be the substitute that u are looking for.
I was looking for alternatives as well and came across a npm package called google-translate-api-browser which does work for my small project, but I can't assure big data translations or requests not being throttled