microsoft / pxt Goto Github PK
View Code? Open in Web Editor NEWMicrosoft MakeCode (PXT - Programming eXperience Toolkit)
Home Page: https://makecode.com
License: MIT License
Microsoft MakeCode (PXT - Programming eXperience Toolkit)
Home Page: https://makecode.com
License: MIT License
Right now, we take the latest version. This may become more of an issue when we support cloud workspaces more widely.
Right now, we do not generate human-readable JavaScript/TypeScript. We could.
Convenience method for brevity and readability.
I'm defining this function in a custom lib:
/**
* Match string against regular expression
* param input The input string, eg: "Hello, World!"
* @param pattern The regular expression, eg: "^Hello"
*/
//% blockId="str_matches" block="%input|matches %pattern"
export function matches(input: string, pattern:string) : boolean { return false; }
If I place an @
in front of the first param entry in the comment, then all custom libs will fail to load in the editor when I refresh the page.
To complete the localization story, we need to:
Try
class Foo {}
new Foo()
See https://github.com/Microsoft/dapjs
Some steps to implement
When string[] appears in a block definition it will not load correctly, making the entire category unusable. Example:
/**
* Prompt the user to choose from a list of choices.
* @param choices The choices to present to the user.
* @param prompt The prompt, eg: "Select a color:"
*/
//% async
//% blockId="bots_choose" block="choose from %choices|with prompt %prompt"
export function choose(choices:string[], prompt:string): string { return ""; }
Support for string manipulation
Some methods are only for blocks really, especially ones using enums
A target should be able to enable floating point math.
When running this script,
let x = 0;
basic.showString(true ? x.toString(): "a")
we get
Live String: "0" refcnt= 1
Also, we don't seem to clear those "live string" counter when we restart the script?
Need to be able to hide built-in blocks as well as put some in my own namespace.
we currently only show help in auto-completion for the entire method not specific parameters
They have different calling convention.
For my pxt target (bot framework), the intention is to host a chat control in the simulator area for interfacing with the bot. The simulator area is a fixed size, but currently too small vertically to host a usable chat control. One solution would be to provide the ability to change the height of the simulator.
Chrome is rejecting the SSL certificate issued for kindscript.com. The error is included below:
Your connection is not private
Attackers might be trying to steal your information from kindscript.com (for example, passwords, messages, or credit cards). NET::ERR_CERT_COMMON_NAME_INVALID
Macbook Air mid 2012
OS X Yosemite : 10.10.5
1.8GHz Core i5
8GB RAM
Version 48.0.2564.116 (64-bit)
For cases when several targets are deployed under a single domain (eg github pages), we need to avoid sharing local storage or workspace between target.
This may be a bug in blockly. In my branch of pxt-sample, I've defined a class as a type that can be assigned to a blockly variable. Using it, I've found a way to create shadow number blocks that are undeletable:
1: Drop a Logic/assignment block
2: Define a block that returns the custom class mentioned above.
3: Drag this block to either argument of the assignment block and attach.
Result: Shadow number wlil pop out and be undeletable from the workspace.
Expected: Shadow number would disappear, or be deletable.
Perhaps a demo username / password should be mentioned in the readme ๐น
Expected to see the warning dialog.
Because we load editor file from there. Do it with nextTick?
Scenario:
An API that allows the runtime (simulated or hardware) to surface a runtime issue in the code editor. We had a simular feature in TD.
I found those BugblockId annotations. Is this supported?
https://github.com/Microsoft/pxt-microbit/blob/master/libs/microbit/images.cpp#L41
We should identify the ARM specific features vs Javascript only features and separate them to provide an optimized experience in both cases.
For example, JSON support is built-in javascript but not required in ARM, etc...
Usage of cards etc
Seperate targets should be able to provide different analytics.
Will require a virtual method table etc
It will also need to be implemented in JS, but there it's trivial.
Yes, rate limiting works!...
*** nvogiv.ts, size=83
*** nujrlc.ts, size=966
ERROR nqxloa: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nqxloa/text; message: {"message":"Too Many Requests"}
ERROR nsaumh: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nsaumh/text; message: {"message":"Too Many Requests"}
ERROR nrjdzu: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nrjdzu/text; message: {"message":"Too Many Requests"}
ERROR nqgyno: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nqgyno/text; message: {"message":"Too Many Requests"}
ERROR npkjbk: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/npkjbk/text; message: {"message":"Too Many Requests"}
ERROR nqdtvd: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nqdtvd/text; message: {"message":"Too Many Requests"}
ERROR noyovd: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/noyovd/text; message: {"message":"Too Many Requests"}
*** ntfmsx.ts, size=252
ERROR novevx: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/novevx/text; message: {"message":"Too Many Requests"}
ERROR noxyjg: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/noxyjg/text; message: {"message":"Too Many Requests"}
ERROR noikvz: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/noikvz/text; message: {"message":"Too Many Requests"}
ERROR noftar: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/noftar/text; message: {"message":"Too Many Requests"}
ERROR nmdfik: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nmdfik/text; message: {"message":"Too Many Requests"}
ERROR nmuhlk: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nmuhlk/text; message: {"message":"Too Many Requests"}
ERROR nmbxkh: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nmbxkh/text; message: {"message":"Too Many Requests"}
ERROR nlyuwy: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nlyuwy/text; message: {"message":"Too Many Requests"}
ERROR nkdbmy: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nkdbmy/text; message: {"message":"Too Many Requests"}
ERROR njynsd: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/njynsd/text; message: {"message":"Too Many Requests"}
ERROR njvcbs: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/njvcbs/text; message: {"message":"Too Many Requests"}
ERROR njfeff: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/njfeff/text; message: {"message":"Too Many Requests"}
ERROR nitcfc: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nitcfc/text; message: {"message":"Too Many Requests"}
ERROR nikzhg: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nikzhg/text; message: {"message":"Too Many Requests"}
ERROR nhtyzy: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nhtyzy/text; message: {"message":"Too Many Requests"}
ERROR nghraa: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nghraa/text; message: {"message":"Too Many Requests"}
ERROR nhpyof: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nhpyof/text; message: {"message":"Too Many Requests"}
ERROR ndqgow: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/ndqgow/text; message: {"message":"Too Many Requests"}
ERROR nfjrxg: Bad HTTP status code: 429 at https://www.microbit.co.uk/api/nfjrxg/text; message: {"message":"Too Many Requests"}
This requires some work, especially on the ARM side
For example:
if (...) {
let x = "a" + "b"
...
// implict 'x = null' here
}
This can free significant amount of memory, especially if 'x' happen to be outside of any function.
Undo failed to remove added block. Sometimes it works but not consistently.
a. Add 2 Blocks (Clear screen and Show String)
b. Move the above blocks together
c. Add a 3rd block (Show Number) and drop right under shows string
d. Click Undo x 2 and the Show number goes away
e. Add 3rd block again (Show String and drop under 2nd block)
f. Click Undo (as many times as you want)
The block may not be removed * 30-50% of the time the block is removed**
Assuming the user has a enum file in the libs, the sims.d.ts should add a reference to it.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.