GithubHelp home page GithubHelp logo

marauders-map's People

Contributors

angusjfw avatar farazcsk avatar mic-css avatar rbrander avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

farazcsk

marauders-map's Issues

stuff

<html>
    <body>
        <script src="https://cdn.pubnub.com/sdk/javascript/pubnub.4.3.2.js"></script>
        <h1> lol </h1>
    </body>


<script>
	function publish() {
   
		pubnub = new PubNub({
		    publishKey : 'pub-c-260e570c-07b0-4988-805c-1c6e0014407d',
		    subscribeKey : 'sub-c-07c504da-b962-11e6-b490-02ee2ddab7fe'
		})
		   
		function publishSampleMessage() {
		    console.log("Since we're publishing on subscribe connectEvent, we're sure we'll receive the following publish.");
		    var publishConfig = {
		        channel : "bla",
		        message : "Hello from PubNub Docs!"
		    }
		    pubnub.publish(publishConfig, function(status, response) {
		        console.log(status, response);
		    })
		}

		
		   
		pubnub.addListener({
		    status: function(statusEvent) {
		        if (statusEvent.category === "PNConnectedCategory") {
		            publishSampleMessage();
		        }
		    },
		    message: function(message) {
		        console.log("New Message!!", message);
		    },
		    presence: function(presenceEvent) {
		        // handle presence
		    }
		})      
		console.log("Subscribing..");
		pubnub.subscribe({
		    channels: ['bla'] 
		});

		pubnub.hereNow(
		    {
		        channels: ["bla"], 
		        includeUUIDs: true,
		        includeState: true
		    },
		    function (status, response) {
		        console.log(status);
		        console.log(response);
		    }
		);

		pubnub.setState(
		    {
		        state: { "username": "lelelleel"},
		        channels: ['bla']
		    },
		    function (status, response) {
		        console.log("set state")
		    }
		);
	};
	
	publish();

</script>
<html>

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.